Hi All
I have a form and there is a graph on it which needs to be filtered using the date range on the form . When I set the row source property of the graph in the property sheet then I don't receive any error message but if the row source is set on the click event of search button then when the form is loaded the following error message appears. Also how can I set the date range criteria for the graph?
"An error occurred while sending data to the OLE server"
The graph is linked to the following query 'qry_RMS_Dashboard_Reasons_Final' which is defined as below:
The query qry_RMS_Dashboard_Reasons is as below:
The query qry_RMS_UnionReasons is as below:
The query qry_RMS_ReturnReasons_1 is as below:
The query qry_RMS_ReturnReasons_2 is as below:
I have a form and there is a graph on it which needs to be filtered using the date range on the form . When I set the row source property of the graph in the property sheet then I don't receive any error message but if the row source is set on the click event of search button then when the form is loaded the following error message appears. Also how can I set the date range criteria for the graph?
"An error occurred while sending data to the OLE server"
The graph is linked to the following query 'qry_RMS_Dashboard_Reasons_Final' which is defined as below:
Code:
TRANSFORM Sum(qry_RMS_Dashboard_Reasons.SumOfTimes) AS SumOfSumOfTimes
SELECT qry_RMS_Dashboard_Reasons.[Staff Name]
FROM qry_RMS_Dashboard_Reasons
GROUP BY qry_RMS_Dashboard_Reasons.[Staff Number], qry_RMS_Dashboard_Reasons.[Staff Name], qry_RMS_Dashboard_Reasons.[Staff Name]
ORDER BY qry_RMS_Dashboard_Reasons.[Staff Name]
PIVOT qry_RMS_Dashboard_Reasons.[1stRefuseReason];
The query qry_RMS_Dashboard_Reasons is as below:
Code:
SELECT qry_RMS_UnionReasons.[Staff Name], qry_RMS_UnionReasons.[1stRefuseReason], Sum(qry_RMS_UnionReasons.Times) AS SumOfTimes, qry_RMS_UnionReasons.[Staff Number]
FROM qry_RMS_UnionReasons
GROUP BY qry_RMS_UnionReasons.[Staff Name], qry_RMS_UnionReasons.[1stRefuseReason], qry_RMS_UnionReasons.[Staff Number];
The query qry_RMS_UnionReasons is as below:
Code:
SELECT *
FROM qry_RMS_ReturnReasons_1 UNION SELECT * FROM qry_RMS_ReturnReasons_2;
The query qry_RMS_ReturnReasons_1 is as below:
Code:
SELECT tblstaff.[Staff Name], tbl_RMS_Paperless1.[1stRefuseReason], Count(tbl_RMS_Paperless1.[1stRefuseReason]) AS Times, tblstaff.[Staff Number]
FROM tbl_RMS_Paperless1 INNER JOIN tblstaff ON tbl_RMS_Paperless1.SupervisorRef = tblstaff.[Staff Number]
GROUP BY tblstaff.[Staff Name], tbl_RMS_Paperless1.[1stRefuseReason], tblstaff.[Staff Number]
HAVING (((tbl_RMS_Paperless1.[1stRefuseReason]) Is Not Null))
ORDER BY Count(tbl_RMS_Paperless1.[1stRefuseReason]) DESC;
The query qry_RMS_ReturnReasons_2 is as below:
Code:
SELECT tblstaff.[Staff Name], tbl_RMS_Paperless1.[2ndRefuseReason], Count(tbl_RMS_Paperless1.[2ndRefuseReason]) AS Times, tblstaff.[Staff Number]
FROM tbl_RMS_Paperless1 INNER JOIN tblstaff ON tbl_RMS_Paperless1.SupervisorRef = tblstaff.[Staff Number]
GROUP BY tblstaff.[Staff Name], tbl_RMS_Paperless1.[2ndRefuseReason], tblstaff.[Staff Number]
HAVING (((tbl_RMS_Paperless1.[2ndRefuseReason]) Is Not Null))
ORDER BY Count(tbl_RMS_Paperless1.[2ndRefuseReason]) DESC;