This scales badly but one possible option depending on use case. int_list would 
be comma separated values stored as a string ("1,2,3,4"). And couldn't really 
find any info is there a limit on the length of the string find_in_set can 
handle (tried with int_list containing 6000 numbers comma separated and worked).

SELECT t1.index,t1.to_join,t2.index
FROM main_table AS t1
LEFT JOIN joined_table AS t2 ON FIND_IN_SET(t1.to_join,t2.int_list)>0

-- Kaj
_______________________________________________
discuss mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to