Mysql dynamic query
- by pradeep
I have two table in mysql
one tbl_a which has one int column id,
second tbl_b which has one column song_ids in which data stored seapated by comma like 1,2,3,4
i want to select all id like this
select * from tbl_a where id in (select song_id from tbl_b)
but its giving me no record as its varchar
HOW to do it in mysql