How to write a simple code for MySQL Multiple Table query?

$db = mysql_connect("localhost","root","root") or dir("can not connect Mysql Server");
mysql_select_db("mydb",$db) or dir("can not connect Mysql Server");

I have many tables under mydb. They all have the same field names.
" id, name, detail, date". The table name is from table001 - table121.
How to make a MySQL Multiple Table query with short code and high efficient? Thanks.

(Apache/2.2.13 , PHP/5.2.11, MySQL 5.0.51a)

What do you want the query to do? Or to put it a better way, what data do you want to collect and what do you want to do with it?

hello, I want do a simple php intranet search. I do not want to write a long long query code.
These tables are some Books directory. book name, book introduction and added date.

that’s going to be a huge problem

really, is there any chance you can combine them into one table?

what was the idea behind separate tables?

Hi r937, each table is one Book directory: such as science, culture, science fiction…
If conbain them, it also will be a big project…

they should definitely be combined