Pete Winter
asked on
sql where issue
See my below code:
WHERE td.call_back_id = ".$row_rs_call_back_reques t['id']." AND td.hide_comment IS NULL OR td.hide_comment = 'No'";
I must be writing it incorrectly as I am not getting the correct result.
I basically want the code after the AND grouped.
i.e.
td.call_back_id = ".$row_rs_call_back_reques t['id']."
AND
(td.hide_comment IS NULL OR = 'No')
I have just put bracket to separate and try to explain what I require, but not sure how to write.
How it makes sense. Ask if not?
WHERE td.call_back_id = ".$row_rs_call_back_reques
I must be writing it incorrectly as I am not getting the correct result.
I basically want the code after the AND grouped.
i.e.
td.call_back_id = ".$row_rs_call_back_reques
AND
(td.hide_comment IS NULL OR = 'No')
I have just put bracket to separate and try to explain what I require, but not sure how to write.
How it makes sense. Ask if not?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER