How to Perform Database Hack-Attach
This blog demonstrates attaching a database on the SQL Server Instance which already has the same name database up and...
2018-04-23
1,814 reads
This blog demonstrates attaching a database on the SQL Server Instance which already has the same name database up and...
2018-04-23
1,814 reads
In the previous blog, we discussed the Foreign Keys Constraints and how the CHECK Constraints are useful to verify the...
2018-04-30 (first published: 2018-04-19)
3,147 reads
DMV (Database Management View) and DMO (Database Management Objects) were added in 2005. There have been huge improvements in each...
2018-04-16
25,987 reads
Recently, while reviewing one of the stored procedure performance, I suggested a couple of changes to a developer to improve...
2018-04-12
19,646 reads
If you are working on SQL Server optimization delicately, you may get often queries that how to find if any...
2018-04-09
965 reads
Yesterday, I was attending a database design meeting. In the meeting, I was asked one of the questions – “How many...
2018-04-12 (first published: 2018-04-05)
12,089 reads
It is relatively easy to spot CPU-bound system. But, the source of CPU pressure is not always easy to pinpoint....
2018-04-02
1,252 reads
It is fun working with SQL/Application developer where you exchange a lot of technical thoughts to find the root of...
2018-03-21
7,312 reads
In my previous post on new functions in SQL Server 2017, I discussed about the STRING_AGG function. Here, I am...
2018-03-02
1,370 reads
For SQL Server 2017 RTM, the fourth cumulative update was released on 20th February, and it is available for download...
2018-03-08 (first published: 2018-03-01)
1,599 reads
By Arun Sirpal
After a year away getting to grips with AI and its application across the...
By SQLPals
Beware of Generic SQL Server License Keys (What to Use Instead) ...
By Brian Kelley
Professor Patrick Winston of MIT used to give a one-hour talk about how to...
Comments posted to this topic are about the item Creating a JSON Document II
By VishnuGupthanSQLPowershellDBA
Comments posted to this topic are about the item Backing Up Azure Key Vault...
Comments posted to this topic are about the item Every Database Has Problems
I want to create a JSON document that contains data from this table:
TeamID TeamNameCity YearEstablished 1 Cowboys Dallas 1960 2 Eagles Philadelphia 1933 3 Packers Green Bay 1919 4 Chiefs Kansas City 1960If I run this code, what document(s) is/are returned?
SELECT json_objectagg( n.city : n.TeamName) FROM dbo.NFLTeams;See possible answers