digarati
asked on
MYSQL OR Statement Help
$query = "select * from vendor where (businessname OR primarycontact OR estimatingcontact OR ownerofficercontact) like \"%$trimmed%\" order by businessname"; // EDIT HERE and specify your table and field names for the SQL query
I am new to using OR statements.
Is my syntax above correct, its returning no results.
If I do just businessname, I have results.
I am new to using OR statements.
Is my syntax above correct, its returning no results.
If I do just businessname, I have results.
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.