Microsoft
Software
Hardware
Network
Question : Why does this query not work?
This query works:
$querystate = "select * from registration WHERE songwriting_contest <> '0000-00-00' AND registration_type <> 'voter' order by first_name";
This query does not:
$querystate = "select * from registration WHERE songwriting_contest <> '0000-00-00' AND AND songwriting_contest < $contest_start AND registration_type <> 'voter' order by first_name";
I've checked the $contest_start value and that's coming up fine, but when I insert it into the query, I get nothing. No errors, but no data.
What am I doing wrong?
Answer : Why does this query not work?
$querystate = "select * from registration WHERE songwriting_contest <> '0000-00-00' AND songwriting_contest < $contest_start AND registration_type <> 'voter' order by first_name";
'you had an extra AND
Random Solutions
Should Sys Admins (Domain Admins) also have user accounts?
navigation buttons wrapping funny
Sorting to Excel workbook to different sheets
Http dynamic Compression not work if We using text/html
FTP not working on Windows Server 2008 IIS 7
Changing color of a shape
create xml script using coldfusion
jQuery Get TD values with only TR id
Microsoft access 2010 pegs the CPU
GFI 2010 Limits exchange 2003 incoming email 2 mb! ARGH!