Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Delete query gives error from JOIN 1

Status
Not open for further replies.

smuthcrmnl777

Technical User
Jan 16, 2006
104
US

When I try to execute this Delete query, I get an error asking me to specify which table I want to Delete. I want to delete the data that match Query2 from tM_FR_WIP_UnitID_FastStops.


Code:
DELETE tM_FR_WIP_UnitID_FastStops.nLine
FROM Query2 INNER JOIN tM_FR_WIP_UnitID_FastStops ON Query2.EndGroup = tM_FR_WIP_UnitID_FastStops.EndGroup
WHERE (((tM_FR_WIP_UnitID_FastStops.nLine) Is Not Null));
 
Remove the field name from the Delete clause.

Code:
DELETE tM_FR_WIP_UnitID_FastStops
FROM Query2 INNER JOIN tM_FR_WIP_UnitID_FastStops ON Query2.EndGroup = tM_FR_WIP_UnitID_FastStops.EndGroup
WHERE (((tM_FR_WIP_UnitID_FastStops.nLine) Is Not Null));

-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
DELETE tM_FR_WIP_UnitID_FastStops.[!]*[/!]
FROM tM_FR_WIP_UnitID_FastStops INNER JOIN Query2 ON tM_FR_WIP_UnitID_FastStops.EndGroup = Query2.EndGroup
WHERE tM_FR_WIP_UnitID_FastStops.nLine Is Not Null;

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top