|
|
-
uzairahm Learned 2 Years ago through Just Learned
I just learned one new thing today "how to get comma separated value(CSV) for every column name in tables with COALESCE function." check out following query.
[code]
Use yourdbname
Go
DECLARE @listStr VARCHAR(MAX)
SELECT @listStr = COALESCE(@listS...
|
-
uzairahm Learned 2 Years ago through Just Learned
I just learned one new thing today "how to get comma separated value(CSV) for every column name in tables with COALESCE function." check out following query.
[code]
Use yourdbname
Go
DECLARE @listStr VARCHAR(MAX)
SELECT @listStr = COALESCE(@listS...
|
-
uzairahm Learned 2 Years ago through Just Learned
I just learned one new thing today "how to get comma separated value(CSV) for every column name in tables with COALESCE function." check out following query.
[code]
Use yourdbname
Go
DECLARE @listStr VARCHAR(MAX)
SELECT @listStr = COALESCE(@listStr+
|
-
uzairahm knew 2 Years ago through Just Learned
Suppose you have three tables named test1,test2 and test3 and you want to drop all these three, you can do it in a single DROP statement
[code]DROP table test1,test2,test3[/code]......
|
-
uzairahm Liked 2 Years ago through Just Learned
Suppose you have three tables named test1,test2 and test3 and you want to drop all these three, you can do it in a single DROP statement
[code]DROP table test1,test2,test3[/code]......
|
-
uzairahm Liked 2 Years ago through Just Learned
Suppose you have three tables named test1,test2 and test3 and you want to drop all these three, you can do it in a single DROP statement
[code]DROP table test1,test2,test3[/code]......
|
-
uzairahm knew 2 Years ago through Just Learned
Suppose you have three tables named test1,test2 and test3 and you want to drop all these three, you can do it in a single DROP statement
[code]DROP table test1,test2,test3[/code]......
|
-
uzairahm Learned 2 Years ago through Just Learned
There is something $IDENTITY to get the identity value for a table contained the identity column.
[Code]
create Table T1(Col1 int identity(1,5),Col2 int)
Go
Insert into T1(Col2) Select 100
Go 100
Select $Identity,* From T1
[/Code]......
|
-
uzairahm Liked 2 Years ago through Just Learned
There is something $IDENTITY to get the identity value for a table contained the identity column.
[Code]
create Table T1(Col1 int identity(1,5),Col2 int)
Go
Insert into T1(Col2) Select 100
Go 100
Select $Identity,* From T1
[/Code]......
|
-
uzairahm Learned 2 Years ago through Just Learned
There is something $IDENTITY to get the identity value for a table contained the identity column.
[Code]
create Table T1(Col1 int identity(1,5),Col2 int)
Go
Insert into T1(Col2) Select 100
Go 100
Select $Identity,* From T1
[/Code]......
|