Popular Posts

SQLblog.com - The SQL Server blog spot on the web

Wednesday, August 23, 2017

Append variable to query

SQLServerCentral » Latest topics
Append variable to query
Hi,

declare @Value varchar (20)
SELECT @Value = case when @Status = 'Y' then '' else 'top 500 ' end

I need to append the above @Value variable result at the start to the below query.

Select @Value CO

No comments: