Query syntax error - need help

  • Thread starter Thread starter David
  • Start date Start date
D

David

I get "Join expression not supported" with this query,
it worked before all I did was rename some columns:

SELECT ChangeRequest.ID, ChangeRequest.Status,
ChangeRequest.ProjectScore, ChangeRequest.Title,
ChangeRequest.Requestor, ChangeRequest.RequestDate,
ChangeRequest.Assigned_To, ChangeRequest.ProjectManager,
ChangeRequest.EstimatedStaffTime,
ChangeRequest.PreliminaryInvestment,
qryAllProjectMonthToDateHoursforReport.MTDHours,
qryAllProjectToDateHoursforReport.PTDHours AS Expr1,
[EstimatedStafftime]-[PTDHours] AS RemainOrigHrs,
ChangeRequest.EstimatedHoursToComplete, [PTDHours]/
([PTDHours]+[EstimatedHoursToComplete]) AS [%Comp],
ChangeRequest.RequestedCompletionDate
FROM qryAllProjectToDateHoursforReport, ChangeRequest LEFT
JOIN qryAllProjectMonthToDateHoursforReport ON
ChangeRequest.Title =
qryAllProjectMonthToDateHoursforReport.Title
WHERE (((ChangeRequest.Status)<>"Closed") AND
((ChangeRequest.Assigned_To)<>"NA") AND
((ChangeRequest.ProjectManager)=[Assigned_To]) AND
((ChangeRequest.Category)="Projects"))
ORDER BY ChangeRequest.Title;
 
David said:
I get "Join expression not supported" with this query,
it worked before all I did was rename some columns:

SELECT ChangeRequest.ID, ChangeRequest.Status,
ChangeRequest.ProjectScore, ChangeRequest.Title,
ChangeRequest.Requestor, ChangeRequest.RequestDate,
ChangeRequest.Assigned_To, ChangeRequest.ProjectManager,
ChangeRequest.EstimatedStaffTime,
ChangeRequest.PreliminaryInvestment,
qryAllProjectMonthToDateHoursforReport.MTDHours,
qryAllProjectToDateHoursforReport.PTDHours AS Expr1,
[EstimatedStafftime]-[PTDHours] AS RemainOrigHrs,
ChangeRequest.EstimatedHoursToComplete, [PTDHours]/
([PTDHours]+[EstimatedHoursToComplete]) AS [%Comp],
ChangeRequest.RequestedCompletionDate
FROM qryAllProjectToDateHoursforReport, ChangeRequest LEFT
JOIN qryAllProjectMonthToDateHoursforReport ON
ChangeRequest.Title =
qryAllProjectMonthToDateHoursforReport.Title
WHERE (((ChangeRequest.Status)<>"Closed") AND
((ChangeRequest.Assigned_To)<>"NA") AND
((ChangeRequest.ProjectManager)=[Assigned_To]) AND
((ChangeRequest.Category)="Projects"))
ORDER BY ChangeRequest.Title;

Hi David,

It sure looks to me like you got an error message
that "means what it says."

shouldn't

FROM qryAllProjectToDateHoursforReport, ChangeRequest LEFT
JOIN qryAllProjectMonthToDateHoursforReport

be

FROM ChangeRequest LEFT
JOIN qryAllProjectMonthToDateHoursforReport

I've never tried to left join a cartesian product to another
query....but I just don't believe that's what you would have
wanted.

Good luck,

Gary Walter
 
Back
Top