Converting Shaped Recordsets into XML
This article shows you how to take a shaped recordset and convert the results into XML all while preserving the shaped recordset hierarchy.
This article shows you how to take a shaped recordset and convert the results into XML all while preserving the shaped recordset hierarchy.
The behavior of SQL Server is influenced in many ways by the various settings and options available. This series will examine some of the ANSI options that can be set and changed in SQL Server.
Get a sneak peak of some of the sections from Start to Finish Guide to SQL Server Performance Monitor. Find out what counters to watch and what their thresholds are.
This article explains how orphan users get created, and provides you with troubleshooting information. A bonus stored procedure called ShowOrphanUsers is included, that goes and searches all the databases and generates a complete list of orphan users.
In this article Andy looks at one way you can separate your presentation code from your data when you generate HTML tables for simple reports. Lots of code examples so you can see how it works.
This article shows you how to design the storage for email addresses, how to validate email addresses, how to retrieve demographic information from email addresses efficiently, using computed columns and indexes. It also covers the security aspect of dealing with email addresses.
A look at a new security tool from Microsoft for analyzing your SQL (and other) servers.
Certy.com has just released SQL Server 2000 certifications. These certifications are 100% free and a must for any DB developer & DBA.
The strength and holy grail of relational databases lies in the very name: relations. Microsoft has put a good deal of intelligence and cunning into query optimizations, caching, indexing and execution plans to make the process of finding related records even smoother and faster. This small article, however, will try to shatter the very sacred notion of relational databases.
Microsoft has released a patch to fix two buffer overflow vulnerabilities in SQL Server 2000. No UserID or password is required by the attacker to exploit these issues. The problem is exacerbated by the fact the attack goes over UDP.
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...
Hi all, I just started using VS Code to work with DB projects. 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
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