G
Guest
I'm trying to delete all records in a table called "Temp_Person" from a
larger table called "Entity_Contact_Join."
Both tables contain two primary key fields "Entity ID" and "Contact ID," so
basically what I'm trying to say is delete every record from
"Entity_Contact_Join" that matches both Entity ID and Contact ID from
Temp_Person.
I am able to construct a Select Query with these two fields as joins, no
problem. When I try to do a delete query, I get message "Could not delete
from specified tables."
I've tried looking up knowledge base and building subqueries based on
previous posts, but all I'm doing is getting more confused and frustrated.
Can someone please translate this SQL code into what I should use instead?
DELETE Entity_Contact_Join.*
FROM Entity_Contact_Join INNER JOIN Temp_Person ON
(Entity_Contact_Join.[Contact ID] = Temp_Person.[Contact ID]) AND
(Entity_Contact_Join.[Entity ID] = Temp_Person.[Entity ID]);
larger table called "Entity_Contact_Join."
Both tables contain two primary key fields "Entity ID" and "Contact ID," so
basically what I'm trying to say is delete every record from
"Entity_Contact_Join" that matches both Entity ID and Contact ID from
Temp_Person.
I am able to construct a Select Query with these two fields as joins, no
problem. When I try to do a delete query, I get message "Could not delete
from specified tables."
I've tried looking up knowledge base and building subqueries based on
previous posts, but all I'm doing is getting more confused and frustrated.
Can someone please translate this SQL code into what I should use instead?
DELETE Entity_Contact_Join.*
FROM Entity_Contact_Join INNER JOIN Temp_Person ON
(Entity_Contact_Join.[Contact ID] = Temp_Person.[Contact ID]) AND
(Entity_Contact_Join.[Entity ID] = Temp_Person.[Entity ID]);