Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
JSON with No root node - Format from XML output - SQL
create table #temp(cid int, name varchar(10),age int, volunteer bit, address varchar(20)) insert into #temp values (1001,'Jack',25,1,'test address1'), (1002,'Brandy',34,0,'test address2'), (1003,'Vincent',14,0,'test address3'), (1004,'Rado',35,1,'test address4') select * from #temp create table #finaldata(cid int,xml_data xml) insert into #finaldata select t.cid, Final = ( select t1.cid, t1.name, t1.age, t1.volunteer, t1.address from #temp t1 where t1.cid = t.cid for xml path('Final'),type) from #temp t select * from #finaldata drop table #temp,#finaldata
run
|
edit
|
history
|
help
0
Availible schedules
product_sales
testing-2
elie homsi's code
Exa
MSQL in 10 mn ~ Lesson 9 Performing Mathematical Calculations - orderitems ~ expanded_price
create table with constraunt
Task_7_Final
Task_3_Final
Gangadhar