Jump to content

Searching 2 tables at the same time


lukep11a

Recommended Posts

Thanks, so if I wanted to search two tables where a particular row from each table was equal to the query and then display results from both tables how would i go about that, I have this code which i know is incorrect but it may help you to understand what i am after..

 

$query = "SELECT * FROM names, directory WHERE names.surname, directory.surname LIKE \"%$trimmed%\" ORDER by surname";

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.