RE: Error message on Where statement
- From: Ofer Cohen <OferCohen@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 31 Mar 2008 10:59:17 -0700
Try
SELECT [Enter Start Date] AS StartDate, [Enter End Date] AS EndDate,
[Monthly Reports]![Resolved by or last Assigned], Count(*) AS [Total Episodes
Resolved]
WHERE ((([Monthly Reports].[Opened]) Between [Enter Start Date] And [Enter
End Date]))
GROUP BY ([Monthly Reports]![Resolved by or last Assigned])
You are missing square brackets in [Resolved by or last Assigned] in the end
--
Good Luck
BS"D
"Frustrated in AL" wrote:
Same error message..
Am I wrong in assuming that the highlighted area of the SQL is the area that
is "having issues" after clicking on the OK of the error message? If not, it
has something to do with the "Where" statement because "Where" is highlighted.
"Ofer Cohen" wrote:
From lookin at the SQL you dont have a space in this line
Count(*)([Monthly Reports]![Resolved by or last Assigned]) AS [Total Episodes
Resolved]
Try
SELECT [Enter Start Date] AS StartDate, [Enter End Date] AS EndDate,
Count(*) AS [Total Episodes Resolved]
WHERE [Monthly Reports].[Opened] Between [Enter Start Date] And [Enter
End Date]
--
Good Luck
BS"D
"Frustrated in AL" wrote:
I seem to be missing something here.
Error Message:
"The SELECT statement includes a reserved word or an argument name that is
misspelled or missing, or the punctuation is incorrect."
The SQL:
PARAMETERS [Enter Start Date] DateTime, [Enter End Date] DateTime;
SELECT [Enter Start Date] AS StartDate, [Enter End Date] AS EndDate,
Count(*)([Monthly Reports]![Resolved by or last Assigned]) AS [Total Episodes
Resolved]
WHERE ((([Monthly Reports].[Opened]) Between [Enter Start Date] And [Enter
End Date]))
GROUP BY ([Monthly Reports]!Resolved by or last Assigned);
When OK is clicked on the error message, the word WHERE is highlighted.
Name of TABLE: "Monthly Reports"
Date range shown in: "Opened" Field
GROUP BY is users, shown in: "Resolved by or last Assigned" Field.
Purpose of Query: Count the number of episodes, within a specific date
range and sort by user.
Any help would be appreciated.
- References:
- Error message on Where statement
- From: Frustrated in AL
- RE: Error message on Where statement
- From: Ofer Cohen
- RE: Error message on Where statement
- From: Frustrated in AL
- Error message on Where statement
- Prev by Date: RE: Error message on Where statement
- Next by Date: RE: Error message on Where statement
- Previous by thread: RE: Error message on Where statement
- Next by thread: RE: Error message on Where statement
- Index(es):
Relevant Pages
|