Grant Fritchey

Grant Fritchey is a SQL Server MVP with over 20 years’ experience in IT including time spent in support and development. Grant has worked with SQL Server since version 6.0 back in 1995. He has developed in VB, VB.Net, C# and Java. Grant has authored books for Apress and Simple-Talk, and joined Red Gate as a Product Advocate in January 2011. Find Grant on Twitter @GFritchey or on his blog as the Scary DBA.

Blog Post

Using AI for Data Conversion

I’m sure I’ve never mentioned that I’m an amateur radio operator. Like Vegans and Cross Fitters, we tend to be shy and withdrawn about our predilections. BWA-HA-HA! Ok, like...

2025-04-28 (first published: )

355 reads

SQLServerCentral Editorial

Life Moves Pretty Fast

Driving my soon-to-be granddaughter to school today (my son is getting married and will adopt the young lady), we saw a dead armadillo, a turtle in the road (rescued it) and an escaped cow (left it alone). THEN... old soon-to-be granddad had forgotten lunch, so had to deliver that back at the school (cow must […]

You rated this post out of 5. Change rating

2025-04-26

68 reads

SQLServerCentral Editorial

Smile and Wave Boys

I won't even try to hide it. I got a huge kick out of the penguin characters in the animated movie, Madagascar. For those who don't know, they're trying to escape the zoo, but are trying to hide that from anyone discovering it. So, they put up a front, "Smile and wave boys. Smile and […]

(2)

You rated this post out of 5. Change rating

2025-03-22

86 reads

SQLServerCentral Editorial

Limits, Not Goals

I just saw one of "those" questions. You know the ones: 'We're hitting an error with a stored procedure. What is the maximum number of parameters you can have?" <sigh> Look, I get it. Breaking the land speed record is cool. Getting the most people into a phone booth (look it up), also cool. Fastest, […]

(3)

You rated this post out of 5. Change rating

2025-02-15

128 reads

Blogs

Optimising Costs: Strategies for Efficient Cloud Resource Management

By

Over time, I’ve realised that one of the hardest parts of cloud management isn’t...

Cost Visibility: Tracking and Analysing Your Cloud Spend

By

One of the biggest challenges I’ve faced in cloud operations is maintaining clear visibility...

Whiling away an afternoon, thinking

By

I come to Heathrow often. Today is likely somewhere close to 60 trips to...

Read the latest Blogs

Forums

Fun with JSON II

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Fun with JSON II

Changing Data Types

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Changing Data Types

Answering Questions On Dropped Columns

By Cláudio Silva

Comments posted to this topic are about the item Answering Questions On Dropped Columns

Visit the forum

Question of the Day

Fun with JSON II

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