DSum Problem (1 Viewer)

dim

Registered User.
Local time
Today, 06:48
Joined
Jul 20, 2012
Messages
54
Hi,

I have a query named BBT with those fields:
Qty, S_Time, M_Time, Planned_Date

I need to calculate in a new field AT:
DSum("[TT]","BBT", [Planned_Date]<=#" & [Planned_Date] & "#")
but for some reasons doesn't work.

The field TT is a calculated field too;
TT: [S_Time]+ (Qty]*[M_Time]

Can you please help with the right expression DSum to calculate the AT ?

Thank you!
 

plog

Banishment Pending
Local time
Today, 05:48
Joined
May 11, 2011
Messages
11,638
Count your parenthesis.
 

plog

Banishment Pending
Local time
Today, 05:48
Joined
May 11, 2011
Messages
11,638
Actually, that's only the syntatical error. You also have a circular logic error as well.

You are not going to be able to do a DSum into the query the Dsum is in. You must either rewrite the DSum to use the underlying table of the query (along with its criteria). Or save BBT and then create another query based on it and do the DSum there.
 

dim

Registered User.
Local time
Today, 06:48
Joined
Jul 20, 2012
Messages
54
Thank you,

You right!
Using another query, is working.
 

Users who are viewing this thread

Top Bottom