The expression is typed incorrectly or it is too complex to be evaluated

G

Guest

I am trying to run the following agregate function in a parameterized query
on Access2000:

Min([t1].[f1]*sqr([t2].[f1]/[t1].[f1])/[param])

The query saved OK, but an attempt to run it results in the message:
The expression is typed incorrectly or it is too complex to be evaluated

If the sintax correct? Perhaps it is, otherwise it would not save.
What can be done about it?
 
J

Jeff Boyce

The error message suggests that the formula is too complex. Could you break
the expression into pieces, doing part of the calculation in each piece,
then use another field to combine the pieces?
 
G

Guest

Can I do this in a query stored in Access?
Does the query syntax allow to do so?
The query which contains this formula is:

SELECT Min([t1].[f1]*sqr([t2].[f1]/[t1].[f1])/[param]) as Something
From ....
Where ...;
 
J

Jeff Boyce

In looking at your expression again, I am struck by your use of the Min()
function. Perhaps you could use one field in a query to generate the value
of your expression, then create a second query, based on the first, and use
the Totals button to find the Min() value?
 
D

Duane Hookom

I would try specify the datatype of the parameter. Select Query|Parameters
and enter the parameter and its data type.

--
Duane Hookom
MS Access MVP


Can I do this in a query stored in Access?
Does the query syntax allow to do so?
The query which contains this formula is:

SELECT Min([t1].[f1]*sqr([t2].[f1]/[t1].[f1])/[param]) as Something
From ....
Where ...;



Jeff Boyce said:
The error message suggests that the formula is too complex. Could you break
the expression into pieces, doing part of the calculation in each piece,
then use another field to combine the pieces?


--
Good luck

Jeff Boyce
<Access MVP>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top