MDX Functions: TopCount
The MultiDimensional eXpressions, or MDX, language is used to query the data in a multidimensional in an OLAP database. In the...
2012-03-12
2,258 reads
The MultiDimensional eXpressions, or MDX, language is used to query the data in a multidimensional in an OLAP database. In the...
2012-03-12
2,258 reads
One dimension you can be positive will always make it’s way into your data warehouse is the Date dimension. Over...
2012-03-06
4,152 reads
Tomorrow at 11AM Eastern time I will be presenting a FREE webinar for Pragmatic Works (website) on Introduction to SharePoint...
2012-03-06
624 reads
I got word this week that one of my sessions for the upcoming SQL Saturday #110 in Tampa, FL was...
2012-02-10
431 reads
If you have ever gotten this error message you may have been left scratching your head wondering why…kinda like me.
The...
2012-01-16
3,881 reads
There are several ways to check the version of SharePoint 2010 currently installed in your environment. That about sums up...
2012-01-11
1,744 reads
You may fire up the SharePoint 2010 Management Shell (which allows you to run PowerShell commands to do cool SharePoint...
2012-01-05
2,235 reads
Restoring a SharePoint site collection can be a pretty easy task. If your interested in how to do that check...
2012-01-04
1,563 reads
Virtualization is awesome! It really helps when you are a developer. On my laptop I don’t even have SQL Server...
2011-12-21
5,393 reads
If you are like me then you like to reinstall Windows on your laptop every few months to keep things...
2011-12-20
898 reads
By Brian Kelley
I will be leading an in-person Certified Information Systems Auditor (CISA) exam prep class...
EightKB is back again for 2026! The biggest online SQL Server internals conference is...
By HeyMo0sh
Working in DevOps long enough teaches you two universal truths: That’s exactly why I...
Comments posted to this topic are about the item Fun with JSON II
Comments posted to this topic are about the item Changing Data Types
Comments posted to this topic are about the item Answering Questions On Dropped Columns
I have some data in a table:
CREATE TABLE #test_data
(
id INT PRIMARY KEY,
name VARCHAR(100),
birth_date DATE
);
-- Step 2: Insert rows
INSERT INTO #test_data
VALUES
(1, 'Olivia', '2025-01-05'),
(2, 'Emma', '2025-03-02'),
(3, 'Liam', '2025-11-15'),
(4, 'Noah', '2025-12-22');
If I run this query, how many rows are returned?
SELECT t1.[key] AS row,
t2.*
FROM OPENJSON(
(
SELECT t.* FROM #test_data AS t FOR JSON PATH
)
) t1
CROSS APPLY OPENJSON(t1.value) t2; See possible answers