Help

amfroehlich

Board Regular
Joined
Jul 14, 2004
Messages
192
I am getting an error saying "Query is too complex". What does this mean? Is their a maximum number of items that can be on a query?
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
an error saying "Query is too complex

Generally it means that Access hasn't been able to 'resolve' some function or other in the query.

Can you post the SQL? Or give some details of the query?
 
Upvote 0
SELECT NumbersofBids.*, NumbersofExpediting.*, NumbersofMSDS.*, NumbersofNewProduct.*
FROM NumbersofBids, NumbersofExpediting, NumbersofMSDS, NumbersofNewProduct;
 
Upvote 0
NumbersofBids, NumbersofExpediting, NumbersofMSDS, NumbersofNewProduct

Are these queries or tables?

Are they linked at all?
 
Upvote 0
no they are not linked.

So why have you got them in a query together?

If you don't link tables Access will return for each record in each query return all the records in the other queries.

A small example
Code:
Table1

x	y
a	b
c	d


Table2

v	w
e	f
g	h

Query 

SELECT Table1.*, Table2.*
FROM Table1, Table2;

returns

x	y	v	w
a	b	e	f
c	d	e	f
a	b	g	h
c	d	g	h

So records in Table1 = 2, records in Table2 = 2 , records returned 2*2.

Adding another table would mutiply the no of records returned again.

This could be causing the error as

No of records returned = No of records in NumbersofBids*No of records in NumbersofExpediting*No of records in NumbersofMSDS*No of records in NumbersofNewProduct

EDIT

Just carried out a 'small' test 5 tables, each table 2 fields and 16 records each:

QUERY

SELECT Table1.*, Table2.*, Table3.*, Table4.*, Table5.*
FROM Table1, Table2, Table3, Table4, Table5;

returns 1,048,576 records.
 
Upvote 0

Forum statistics

Threads
1,221,816
Messages
6,162,149
Members
451,746
Latest member
samwalrus

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top