If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
HELP WITH AGGREGATE FUNCTION
I'm having a terrible time figuring this one out and I was hoping someone can
help me out. I'm trying to capture the sum of all items that are between 31 to 60 days here's my query(Parameter) entry: 31-59: IIf([Age] Between 31 And 59,[tblSAP EXCEL DOWNLOAD]![Amount in Local Cur],0) Where Age refers to the following aggregate function on the same query: Age: DateDiff("d",[tblSAP EXCEL DOWNLOAD]![Net Due Date],Now()) Criteria for AGE, Between CInt([From Age]) And CInt([To Age]) This works when their's no totals involved, as soon as I want to run with totals, I get an error message. Anyone that can help I would really appreciated. |
#2
|
|||
|
|||
HELP WITH AGGREGATE FUNCTION
I would try including the original expression in place of [Age]
31-59: IIf(DateDiff("d",[tblSAP EXCEL DOWNLOAD]![Net Due Date],Now()) Between 31 And 59,[tblSAP EXCEL DOWNLOAD]![Amount in Local Cur],0) '================================================= === John Spencer Access MVP 2002-2005, 2007-2008 The Hilltop Institute University of Maryland Baltimore County '================================================= === Alisheba wrote: I'm having a terrible time figuring this one out and I was hoping someone can help me out. I'm trying to capture the sum of all items that are between 31 to 60 days here's my query(Parameter) entry: 31-59: IIf([Age] Between 31 And 59,[tblSAP EXCEL DOWNLOAD]![Amount in Local Cur],0) Where Age refers to the following aggregate function on the same query: Age: DateDiff("d",[tblSAP EXCEL DOWNLOAD]![Net Due Date],Now()) Criteria for AGE, Between CInt([From Age]) And CInt([To Age]) This works when their's no totals involved, as soon as I want to run with totals, I get an error message. Anyone that can help I would really appreciated. |
Thread Tools | |
Display Modes | |
|
|