Calculated fields in query
From: Steve (anonymous_at_discussions.microsoft.com)
Date: 07/23/04
- Next message: Susan: "Confusing date difference problem"
- Previous message: Allen Browne: "Re: Calculated fields in query"
- In reply to: Christopher: "Calculated fields in query"
- Next in thread: Christopher: "Calculated fields in query"
- Reply: Christopher: "Calculated fields in query"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 23 Jul 2004 04:48:05 -0700
Hi
what you could do is first create a query that totals the
days taken by each employee etc.
Use that query in a non totalled query and it should do
the trick.
eg: qryTotalDaysTaken(2 Fields)
ID DaysTaken
GroupBy Sum
eg: qryAllowanceRemaining(4 Fields)
ID Allowance SumOfDaysTaken
tblAllowance tblAllowance qryTotalDaysTaken
TotalRem:Allowance-SumOfDaysTaken
>-----Original Message-----
>Hi
>
>I am stuck here and need some help with this one.
>I have a select query which I need to calculate the
>following operation:
>
>The first field:
>[DaysAllowance]
>GroupBy
>
>The second field:
>[Days Taken]
>Sum
>
>For The third field:
>[DaysAllowance]-[Days Taken]
>Expression (does not seem to like another Sum)?
>The query returns the value 20 whereas it should return
0,
>as the first field value is 20 and the second field is
>also 20.
>I really am scratching my head with this one.
>Thanks for your help.
>Chrisopher
>.
>
- Next message: Susan: "Confusing date difference problem"
- Previous message: Allen Browne: "Re: Calculated fields in query"
- In reply to: Christopher: "Calculated fields in query"
- Next in thread: Christopher: "Calculated fields in query"
- Reply: Christopher: "Calculated fields in query"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|