Search
 
SCRIPT & CODE EXAMPLE
 

SQL

row to value to json in sql server

SELECT BusinessEntityID As Id,  
       FirstName, LastName,  
       Title As 'Info.Title',  
       MiddleName As 'Info.MiddleName'  
   FROM Person  
   FOR JSON PATH, ROOT('info'),INCLUDE_NULL_VALUES
Comment

row to json in sql server

SELECT * 
FROM MyTable  
FOR JSON PATH, WITHOUT_ARRAY_WRAPPER
Comment

PREVIOUS NEXT
Code Example
Sql :: sql server select last row of each item in group by column 
Sql :: increment integer in table sql 
Sql :: restart serial number for postgres 
Sql :: mysql 8 geo to json 
Sql :: get max salary from each department sql 
Sql :: sql change data type 
Sql :: sqlite unique multiple columns 
Sql :: set all auto_increment values in sql 
Sql :: sql select lowest value row 
Sql :: cast datetime to date in sql 
Sql :: update foreign key value in mysql 
Sql :: unique key in ms sql server 
Sql :: postgres integer to serial 
Sql :: sqlalchemy empty table 
Sql :: sql in 
Sql :: is sql fast 
Sql :: sql server current time without date 
Sql :: mysql count rows returned 
Sql :: sql query to check if column contains alphabets 
Sql :: how to pass dynamic column name in sql query 
Sql :: sql create table with data 
Sql :: select only one row sql 
Sql :: How to import CSV file into a MySQL table 
Sql :: SQLITE_BUSY: database is locked 
Sql :: mysql timezone 
Sql :: sql update 
Sql :: soql user profile 
Sql :: mysql command 
Sql :: right join sql 
Sql :: SQL get last 5 minutes data 
ADD CONTENT
Topic
Content
Source link
Name
4+5 =