I have query like below
select * from table1 where id in (select ids from table2 where id = 100)
The subquery returns me output like 34,35,55,66 if i run it individually.
But my above query gives error as
Conversion failed when converting the varchar value '34,35,55,56' to data type int.
The id column in table1 is int. I am aware that i can do this in 2 seperate queries but if there is any way to do in single query then please let me know. Many thanks in advance