How to fix: Data type mismatch criteria expression

G

Guest

Greetings
I'd like to count\sum a list of records seperately for different
individuals. For example, I have a table that contains different statuses
for these individuals, such as Other, Vacation, Personal Holiday, Training
and Sick. The problem is each status is listed under one (1) field "Absent
Type". How can I run a report that will seperate them.
i.e. John Doe Other 0, Vacation 10, Personal Holiday 1, Training 2 and Sick
20.
I have tried to run the query with Absent Type Group By and Absent Type Sum,
when I run it this way, I get the imfamous Data type mismatch criteria
expression message.
 
M

[MVP] S.Clark

Something along the lines of:

Select EmpID, EmpName, AbsentType, Count(AbsentType) from tblEmployee
INNER JOIN tblEmployeeAbsent ON Empid = EmpID
Group By EmpID, AbsentTypeID

You can also crosstab it to, to get a more horizontal layout.

--
Steve Clark, Access MVP
FMS, Inc.
Call us for all of your Access Development Needs!
1-888-220-6234
(e-mail address removed)
www.fmsinc.com/consulting
 
G

Guest

Hey Karl
Thanks a million. I am about try this shortly.
I do appreciate your quick response.

Martin
 
G

Guest

SClark
Cool. I really appreciate the SQL lines, they will be a huge help!
Thanks again and I appreciate your quick response.

Martin
 

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