Viewing 3 posts - 31 through 33 (of 33 total)
bopeavy, kramaswamy is right.
My query gives me the right result and you have the same. I am trying to avoid 2 joins that is all.
Thanks for the attempt. ...
July 14, 2011 at 12:05 pm
#1353019
Thanks Dixie Flatline ,
I will try this..
My Table1 is dynamic meaning it is table(x) the columns can be different since it may be from another table.
so, I cannot hard code...
December 15, 2010 at 6:30 pm
#1263249
I am not sure why nobody is posting replies but I found solution below.
declare @cols nvarchar(max), @sql nvarchar(max), @TableName varchar(10) ='Table1'
select @Cols = stuff((select ', ' + quotename(Column_Name)...
December 15, 2010 at 5:01 pm
#1263234