Hierarchies in SQL
One very common structure that needs to be handled in T-SQL is the hierarchy. One of our prominent members of the community discusses how you can handle hierarchies in SQL Server.
One very common structure that needs to be handled in T-SQL is the hierarchy. One of our prominent members of the community discusses how you can handle hierarchies in SQL Server.
Three contests from Red Gate Software are coming next week. Get a hint about what might be coming and set a reminder on your calendar.
One piece of advice that is often given to new SQL Server administrators is not to shrink their databases. But they seem to do it often enough anyway. For this Friday's poll, Steve Jones asks if we should do away with shrink.
Cross-posted from a Goal Keeping DBA blog:
Just recently, my oldest son entered the ranks of the teenagers. I shouldn’t actually...
I’ve been pretty quite since the PASS Summit and with good reason. Every year we have a chapter leader meeting....
Data warehousing and general reporting applications tend to be CPU intensive because they need to read and process a large number of rows. To facilitate quick data processing for queries that touch a large amount of data, Microsoft SQL Server exploits the power of multiple logical processors to provide parallel query processing operations such as parallel scans. Through extensive testing, we have learned that, for most large queries that are executed in a parallel fashion, SQL Server can deliver linear or nearly linear response time speedup as the number of logical processors increases. However, some queries in high parallelism scenarios perform suboptimally. There are also some parallelism issues that can occur in a multi-user parallel query workload. This white paper describes parallel performance problems you might encounter when you run such queries and workloads, and it explains why these issues occur. In addition, it presents how data warehouse developers can detect these issues, and how they can work around them or mitigate them.
Microsoft is working to certify vendors to build private clouds, which Steve Jones thinks is a great idea.
A look at what's happening with the SQLServerCentral servers based on the public information exposed by SQL Monitor.
Normalization is standard practice in database design, however, an over-normalized database can have issues. This article examines the case for denormalization.
The call for speakers is open through December 15, 2010, and I hope many of you will take the chance...
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