in reply to Perl/MySQL Problem
active != "0"
isn't it supposed to be "<>" for not equals in SQL?
also, use brackets when you've got complicated ANDs and ORs, it'll help you see it better, like:
and are you supposed to be quoting number values?SELECT * FROM users WHERE (state = "FL" OR state = "NY") AND (active <> 0)
I've now reached the end of my SQL knowledge, but is there a difference between active=0 and active="0"? If it's the contents of a number-type field?
--
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Perl/MySQL Problem
by biograd (Friar) on Feb 24, 2002 at 20:40 UTC |