Hello.
When i use the following string in a "DoCmd.OpenReport stDocName, acViewPreview, , strWhere", it gives me the report i want:
"[COMPANY NAME] = 'A V H INTERIORS 4061' AND TempStatus.JOBNO In (SELECT JOBNO FROM TempStatus WHERE WORKSTATION= '#2- RECEIVED' AND [TempStatus].TIMESTAMP Between #01/01/2004# And #1/01/2054#)"
Yet if i use this string, it takes forever to get a report. Can somebody explain why ?
" TempStatus.JOBNO In (SELECT JOBNO FROM TempStatus WHERE WORKSTATION= '#2- RECEIVED' AND [TempStatus].TIMESTAMP Between #01/01/2004# And #01/01/2054#)"
Here is the query that is the Record Source for the report.
SELECT DISTINCT TempStatus.WORKSTATION, TempStatus.TIMESTAMP,
TempStatus.JOBNO, [PENDING ORDERS].DESCRIPTION, [PENDING ORDERS].TARGET, [PENDING ORDERS].[COMPANY NAME], [PENDING ORDERS].SIDEMARK, [PENDING ORDERS].TIMESTAMP, [PENDING ORDERS].[NUMBER OF FABRICS], INSTALL.INSTALLER,
INSTALL.[INSTALL DATE], INSTALL.[INSTALL NOTES], INSTALL.WORKSTATION, INSTALL.TIMESTAMP
FROM ([PENDING ORDERS] LEFT JOIN TempStatus ON [PENDING
ORDERS].JOBNO=TempStatus.JOBNO) LEFT JOIN INSTALL ON [PENDING ORDERS].JOBNO=INSTALL.[JOB NO]
ORDER BY TempStatus.TIMESTAMP;
Any help would be greatly appreciated.
Thanks,
Tony
When i use the following string in a "DoCmd.OpenReport stDocName, acViewPreview, , strWhere", it gives me the report i want:
"[COMPANY NAME] = 'A V H INTERIORS 4061' AND TempStatus.JOBNO In (SELECT JOBNO FROM TempStatus WHERE WORKSTATION= '#2- RECEIVED' AND [TempStatus].TIMESTAMP Between #01/01/2004# And #1/01/2054#)"
Yet if i use this string, it takes forever to get a report. Can somebody explain why ?
" TempStatus.JOBNO In (SELECT JOBNO FROM TempStatus WHERE WORKSTATION= '#2- RECEIVED' AND [TempStatus].TIMESTAMP Between #01/01/2004# And #01/01/2054#)"
Here is the query that is the Record Source for the report.
SELECT DISTINCT TempStatus.WORKSTATION, TempStatus.TIMESTAMP,
TempStatus.JOBNO, [PENDING ORDERS].DESCRIPTION, [PENDING ORDERS].TARGET, [PENDING ORDERS].[COMPANY NAME], [PENDING ORDERS].SIDEMARK, [PENDING ORDERS].TIMESTAMP, [PENDING ORDERS].[NUMBER OF FABRICS], INSTALL.INSTALLER,
INSTALL.[INSTALL DATE], INSTALL.[INSTALL NOTES], INSTALL.WORKSTATION, INSTALL.TIMESTAMP
FROM ([PENDING ORDERS] LEFT JOIN TempStatus ON [PENDING
ORDERS].JOBNO=TempStatus.JOBNO) LEFT JOIN INSTALL ON [PENDING ORDERS].JOBNO=INSTALL.[JOB NO]
ORDER BY TempStatus.TIMESTAMP;
Any help would be greatly appreciated.
Thanks,
Tony