Advertisement

05.26.2008 at 08:11AM PDT, ID: 23432778
[x]
Attachment Details

Delete records from multiple tables

Asked by jiiins2 in SQL Server 2005, SQL Query Syntax

Tags: Microsoft, SQL Express, 2005

Hello,

in a SQL Express db, I'm trying to delete rows from 3 different tables. Basically, I'd like to delete the result of the following query:

SELECT *
FROM tbPartners, tbClients, tbTrans
WHERE tbClients.ClientVar <> 11 AND tbClients.PartIndex = tbPartners.PartIndex AND tbClients.ClientIndex = tbTrans.ClientIndex

What's the best way to accomplish this, assuming that the result might count several hundreds records?

Thanks!
JStart Free Trial
[+][-]05.26.2008 at 08:18AM PDT, ID: 21646788

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.26.2008 at 08:20AM PDT, ID: 21646804

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: SQL Server 2005, SQL Query Syntax
Tags: Microsoft, SQL Express, 2005
Sign Up Now!
Solution Provided By: chapmandew
Participating Experts: 4
Solution Grade: B
 
 
[+][-]05.26.2008 at 10:34AM PDT, ID: 21647370

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.26.2008 at 08:08PM PDT, ID: 21649138

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.26.2008 at 08:12PM PDT, ID: 21649156

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]05.26.2008 at 08:22PM PDT, ID: 21649180

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.26.2008 at 08:26PM PDT, ID: 21649192

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.26.2008 at 08:34PM PDT, ID: 21649204

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.26.2008 at 09:38PM PDT, ID: 21649373

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.29.2008 at 06:11PM PDT, ID: 21674580

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628