|
A "problem" realted to the title of the base note but not the
content:
I somehow ended up with a query that had 4 tables, and output
fields from all 4 tables, but no indicated relationships between
the tables [IE, there was no joining of fields specified]. So I
ran it, and it went on and on for a long time before I finally
stopped it.
What was Access trying to do? I figured it'd give me the output
from all 4 tables in succession with no matching records from
the other tables:
Field Field Field Field Field Field Field Field
1 1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
So, what WAS it trying to do?
|
|
Apparently this will produce a 'Cartesian product', which Help defines as:
"Cartesian product
The result of joining two relational tables, producing all possible ordered
combinations of rows from the first table with all rows from the second
table.
Generally, a cartesian product results from executing a SQL SELECT statement
referencing two or more tables in the FROM clause and not including a WHERE
or JOIN clause that indicates how the tables are to be joined."
That means that if the four tables have N1, N2, N3 and N4 records in them
respectively, the output will be a recordset with N1 * N2 * N3 * N4 records.
This is standard relational database behaviour.
Brian.
|