On 26 Apr 2004 at 14:59, Matthias Eireiner wrote:

> how can I simplify multiple OR statements in a WHERE clause where I
> have only one column to which I refer?
> 
> e.g. 
> 
> SELECT word FROM word_table WHERE id = 1 OR id = 34 OR id = 78 OR id =
> 8787 OR ...

You want the "IN" operator:

http://dev.mysql.com/doc/mysql/en/Comparison_Operators.html#IDX1209

-- 
Keith C. Ivey <[EMAIL PROTECTED]>
Tobacco Documents Online
http://tobaccodocuments.org


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to