I know there has to be a better way to evaluate a set of repeating variables against multiple columns. I've been searching for a while and still don't have a great solution. Is there a better way to do this?
SELECT *
FROM TABLE
WHERE
SELECT *
FROM TABLE
WHERE
(SUBSTRING(COLUMN1,1,3) IN ('val1','val2','val3','val4'...REPEATS to 30)
OR SUBSTRING(COLUMN2,1,3) IN ('val1','val2','val3','val4'...REPEATS to 30)
OR SUBSTRING(COLUMN3,1,3) IN ('val1','val2','val3','val4'...REPEATS to 30)
OR SUBSTRING(COLUMN4,1,3) IN ('val1','val2','val3','val4'...REPEATS to 30)
OR SUBSTRING(COLUMN5,1,3) IN ('val1','val2','val3','val4'...REPEATS to 30))
...REPEATS 5 MORE TIMES
REPEATS 5 MORE TIMES