I believe you would need the bitwise "and" (&). J.R.
-----Original Message----- From: Diane Schips [mailto:[EMAIL PROTECTED]] Sent: Wednesday, October 02, 2002 10:28 AM To: [EMAIL PROTECTED] Subject: [wdvltalk] SQL search using bitwise operation? I want to search through a table returning all records where, say, bit 2 is set. How to I do this? Say I'm concerned with a field called bit. I've tried the following: strSQL = "SELECT * FROM test WHERE (bit AND 2) = true" This doesn't work. What am I doing wrong? Diane ____ � The WDVL Discussion List from WDVL.COM � ____ To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] Send Your Posts To: [EMAIL PROTECTED] To change subscription settings to the wdvltalk digest version: http://wdvl.internet.com/WDVL/Forum/#sub ________________ http://www.wdvl.com _______________________ You are currently subscribed to wdvltalk as: [EMAIL PROTECTED] To unsubscribe send a blank email to %%email.unsub%% ____ � The WDVL Discussion List from WDVL.COM � ____ To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] Send Your Posts To: [EMAIL PROTECTED] To change subscription settings to the wdvltalk digest version: http://wdvl.internet.com/WDVL/Forum/#sub ________________ http://www.wdvl.com _______________________ You are currently subscribed to wdvltalk as: [email protected] To unsubscribe send a blank email to [EMAIL PROTECTED]
