Use of coalesce with temporary variables in sql and concept of single quotes? -
I have created a stored procedure, I am getting the error due to the same quotation from the wrong places -> wrong Near the syntax = in (@l = colases) Can it help !!! ??
code:
set @ q = n'select '+ @ l = COALESCE (@l +', ',' ') +' + FROM from attribute_names' + @ Tablename print @q EXEC sp_executesql @q
Comments
Post a Comment