S
scubadiver
I am trying to create a "Totals" query based on another query. The source
query has a set of calculations between dates and I want the "Totals" query
to give me the number of records grouped by time taken (basically a frequency
distribution).
Neither query has criteria expressions yet I am getting a "data type
mismatch in criteria expression" error and I can't see why.
Source query SQL:
SELECT tble_Query.QueryID, tble_Query.Qry_ELS, tble_Query.Qry_Status,
tble_Query.CreInv, tble_Query.Cont_InvName,
WorkingDays2([SLA_Date1],[SLA_Date2]) AS Logged,
WorkingDays2([SLA_Date2],[SLA_Date3]) AS Timetaken,
WorkingDays2([SLA_Date1],[SLA_Date3]) AS Completed,
WorkingDays2([SLA_Date1],[SLA_Date4]) AS Preventative,
WorkingDays2([SLA_Date1],[SLA_Date5]) AS Authorised,
WorkingDays2([SLA_Date1],[SLA_Date6]) AS Billing,
WorkingDays2([SLA_Date1],[SLA_Date7]) AS Completion
FROM tble_Query;
Second query SQL:
SELECT [SLA Master].Timetaken, Count([SLA Master].Timetaken) AS
CountOfTimetaken, [SLA Master].Qry_Status
FROM [SLA Master]
GROUP BY [SLA Master].Timetaken, [SLA Master].Qry_Status;
query has a set of calculations between dates and I want the "Totals" query
to give me the number of records grouped by time taken (basically a frequency
distribution).
Neither query has criteria expressions yet I am getting a "data type
mismatch in criteria expression" error and I can't see why.
Source query SQL:
SELECT tble_Query.QueryID, tble_Query.Qry_ELS, tble_Query.Qry_Status,
tble_Query.CreInv, tble_Query.Cont_InvName,
WorkingDays2([SLA_Date1],[SLA_Date2]) AS Logged,
WorkingDays2([SLA_Date2],[SLA_Date3]) AS Timetaken,
WorkingDays2([SLA_Date1],[SLA_Date3]) AS Completed,
WorkingDays2([SLA_Date1],[SLA_Date4]) AS Preventative,
WorkingDays2([SLA_Date1],[SLA_Date5]) AS Authorised,
WorkingDays2([SLA_Date1],[SLA_Date6]) AS Billing,
WorkingDays2([SLA_Date1],[SLA_Date7]) AS Completion
FROM tble_Query;
Second query SQL:
SELECT [SLA Master].Timetaken, Count([SLA Master].Timetaken) AS
CountOfTimetaken, [SLA Master].Qry_Status
FROM [SLA Master]
GROUP BY [SLA Master].Timetaken, [SLA Master].Qry_Status;