Solved

Could not delete from specified tables

Posted on 2010-09-15
6
760 Views
Last Modified: 2013-11-28
Hello,

I am receiving "Could not delete from specified tables" error when using this code.  Appreciate the help.

DELETE [Assignment - Deployed].*, [Project List].[Project Status]
FROM [Assignment - Deployed] INNER JOIN [Project List] ON [Assignment - Deployed].[Project ID] = [Project List].[Project ID]
WHERE ((([Project List].[Project Status])="Complete"));
0
Comment
Question by:dustywork
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 40

Expert Comment

by:als315
ID: 33683599
Is [Project List].[Project ID] key field?
 
0
 

Author Comment

by:dustywork
ID: 33683883
Yes.  Project ID is a key field in the Project List table.
0
 

Expert Comment

by:Lee-H
ID: 33683884
Do you have enforce referential integrity enabled on your relationships?
0
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 125 total points
ID: 33683927
try this


DELETE [Assignment - Deployed].*
FROM [Assignment - Deployed], [Project List]
Where [Assignment - Deployed].[Project ID]
  IN (select [Project ID] from [Project List]
WHERE [Project Status]="Complete")
0
 
LVL 65

Assisted Solution

by:rockiroads
rockiroads earned 125 total points
ID: 33683939
your delete query contains multiple tables. if just deleting from one table then specify just that or try the UniqueRecords setting http://support.microsoft.com/kb/240098/en-us
0
 

Author Closing Comment

by:dustywork
ID: 33684646
Thanks to you both as I needed both to get to the solution.
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question