"Could not delete from specified table" Error

  • Thread starter Eric @ CMN, Evansville
  • Start date
E

Eric @ CMN, Evansville

When attempting to run the following query I got the "Could not delete from
specified table" Error. Any ideas why ?

DELETE Raw.*
FROM Raw INNER JOIN [raw data 2b deleted] ON (Raw.ATTR = [raw data 2b
deleted].MinOfATTR) AND (Raw.[Ticket Number] = [raw data 2b deleted].[Ticket
Number]);
 
A

Allen Browne

Try something like this:

DELETE FROM Raw
WHERE EXISTS
(SELECT MinOfATTR
FROM [raw data 2b deleted]
WHERE (Raw.ATTR = [raw data 2b deleted].MinOfATTR)
AND (Raw.[Ticket Number] = [raw data 2b deleted].[Ticket Number]));

If subqueries are new, see:
How to Create and Use Subqueries
at:
http://support.microsoft.com/?id=209066

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

in message
news:[email protected]...
 
Top