Syntax error with WHERE
Posted: Mon Mar 03, 2008 5:03 pm
I am new to this so I assume this is a very stupid error, but I have a field in my table called signoff_status and the type is ENUM. The values in enum are "s" or "a".
Here's the code:
$query = "SELECT patient_name, mrn, location, fellow, rcf_date, admission, consult_reason, impression, recs, comments ".
"FROM active_consults ORDER BY patient_name".
"WHERE signoff_status = 'a' ";
I get the error at the where line.
Basically I just want to display records that have an "a" in the signoff_status field.
Here's the code:
$query = "SELECT patient_name, mrn, location, fellow, rcf_date, admission, consult_reason, impression, recs, comments ".
"FROM active_consults ORDER BY patient_name".
"WHERE signoff_status = 'a' ";
I get the error at the where line.
Basically I just want to display records that have an "a" in the signoff_status field.