Hello Jason,
This example you put here is a cartesian product. The DB will output a cartesian produict between table 1 and table2.
If you have a table
PRODUCT
PRODUCT_ID
PRODUCT_NAME
with 10 rows
and a table
PERSON
PERSON_ID,
PERSON_NAME
with 11 rows
the select * from PRODUCT, PERSON
will return 10*11=110 rows with all data from product and person. Each row with 4 fields(PERSON_ID, PERSON_NAME, PRODUCT_ID, PRODUCT_NAME). You may figure out something like: for each ocurrence on an product will bring all persons.
Regrads
jason wrote:
table 1 and table 2 have no fields in common,my query is:
select * from table1,table2 where table1.col like '$search%' or table2.col like '$search%';
what's the result?
who can give me a example about select in mutitable.
Thanks a lot.