something like
select * from employee where employeeID in (@.empid)
when I send @.empid = 1,2,3 , it shows a compiler error ,
"syntax error converting the nvarchar value '1,2,3' to a column of data type int'.
any workarounds?Hi,
you can use a function to convert string type CSV into table of integer values (which work for IN). That is of course if you collect the values into string type CSV.
Using a CSV with an IN sub-select|||check booksonline about using sp_executesql..might give you an idea..
hth|||Solved it using the csv funtion, Thank you all.
No comments:
Post a Comment