Hai all,
I need to do the following...
declare @strwhere varchar(100)
set @strwhere = ' and col2 = 6' -- where columnname is an integer datatype.
select * from <tablename> where col1 = 'B' + @strwhere
but the above query is not working when @strwhere takes a where condition
for an integer datatype. How can i do this..i don't want to use
sp_executesql..
Is there any other way to do this?
Thanks,