SQL Variables and 'IN' statements. - TechRepublic
General discussion
July 17, 2001 at 01:08 PM
bhicks

SQL Variables and ‘IN’ statements.

by bhicks . Updated 24 years, 8 months ago

Is it possible to use a variable with an ‘IN’ statement in an SQL procedure ie.

@variable is a text string = ‘test1′,’test2’

SELECT column1_name
FROM table_name
WHERE column2_name IN @variable

This discussion is locked

All Comments