delete rows using sql 'like' command using data from another table
Posted
by
Captastic
on Stack Overflow
See other posts from Stack Overflow
or by Captastic
Published on 2011-01-05T15:41:50Z
Indexed on
2011/01/05
15:53 UTC
Read the original article
Hit count: 155
Hi All,
I am trying to delete rows from a table ("lovalarm") where a field ("pointid") is like any one of a number of strings.
Currently I am entering them all manually however I need to be able to have a list of over 100,000 options.
My thoughts are to have a table ("lovdata") containing all possible strings and running a query to delete rows where the field is 'like' any of the strings in the other table.
Can anyone point me in the right direction as to if/how I can use like in this way?
Many thanks, Cap
© Stack Overflow or respective owner