does anyone know how to search all the fields in a database table for a specific string. I know how to search specific fields but i'd like to know how to search the entire table.
For example let's say my table named 'employees' has the fields 'firstname, lastname, ssn, city, address, state' all type var.
"select firstname from employees where firstname like '%john%' order by firstname"
Now that query only searches the firstname field for anything that contains john. Is there a way i can search all the fields without having to specify each column individually.
Thanks for the help.
For example let's say my table named 'employees' has the fields 'firstname, lastname, ssn, city, address, state' all type var.
"select firstname from employees where firstname like '%john%' order by firstname"
Now that query only searches the firstname field for anything that contains john. Is there a way i can search all the fields without having to specify each column individually.
Thanks for the help.