View Single Post
  #6  
Old April 19th, 2006, 01:21 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default I'm stuck can not get total sum correct

Using those expression it counts all them I need for them to count each
department and employee separately on their report. If John have 2 accident
in the Road Dept I need to see on John report dept Total 2 and Empoyee
total=2 but if Steve get and accident in the Road Dept I need for Steve to
show on his report dept total =3 and employee total=1. Likewise with the
rest, the count for employees does not work at all I get zero for the result.

I use this function and I am getting character for my results not a numeric
answer
=nz(DLookUp("Department","[qry Employee Accident]"),0)


any help is appreciated
--
LHEMA


"AccessVandal via AccessMonster.com" wrote:

Department and EmployeeID are of text values, you can't add them.

Do something like,

Count([Department])
Count([EmployeeID])


LHEMA wrote:
I get a data mismatch when i try those two. I use this expression and I am
not getting a numeric answer here is the expression:
=nz(DLookUp("Department","[qry Employee Accident]"),0) the results from
this expression is the department number such as 42200 Road Dept
and and for employee total i use this expression: =Sum(nz([EmployeeID])) and
its giving me a total of the employeeID not a numeric value of 1 or 2. I have
3 reports and in each report I need a separate total for each employee. If
Robert had 3 accident in this department then I need to see in my report
employee total = 3 and department total =3 but if John gets 1 accident in the
road department I need to see on john report employee total=1 and department
total=4...I hope I am making since. Thank you

Try This =Sum(nz([Department]))
and =Sum(nz([EmployeeID]))

[quoted text clipped - 6 lines]
=Sum([EmployeeID]). Using this expression I get a mismatch data type. Any
help is appreciation.


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...ports/200604/1