Article View: borland.public.interbase.sql
Article #238Re: Help with a "not in" query
From: Hugo
Date: Mon, 16 Jun 2008 16:58
Date: Mon, 16 Jun 2008 16:58
26 lines
1508 bytes
1508 bytes
Bill Todd [TeamB] escribi๏ฟฝ:
> Your original post did not mention deleting records.
>
> DELETE FROM TABLE_1
> WHERE ID_ARTICULO IN
> (SELECT ID_ARTICULO FROM...)
>
True
Sorry, first I wanted to make a select to understand it better, So, it
would be something like:
DELETE FROM TABLE_1
WHERE ID_VENTA = 20081398
AND OPCION = 1
AND ID_ARTICULO NOT IN (
SELECT ID_ARTICULO FROM TABLE_2
WHERE ID_VENTA = 20081398
AND OPCION = 1);
regards,
Hugo.
Technical Details
Message-ID:
<48569bb2$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news1.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<48558e17$1@newsgroups.borland.com> <4855914f$1@newsgroups.borland.com> <48559360$1@newsgroups.borland.com> <48559a04$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 114a0e,82d9b914a86c4cad X-Google-Attributes: gid114a0e,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Date: Mon, 16 Jun 2008 18:58:24 +0200 From: Hugo <hugo@hugohiram.com> User-Agent: Thunderbird 2.0.0.14 (Windows/20080421) MIME-Version: 1.0 Newsgroups: borland.public.interbase.sql Subject: Re: Help with a "not in" query References: <48558e17$1@newsgroups.borland.com> <4855914f$1@newsgroups.borland.com> <48559360$1@newsgroups.borland.com> <48559a04$1@newsgroups.borland.com> In-Reply-To: <48559a04$1@newsgroups.borland.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit NNTP-Posting-Host: 77.224.139.205 Message-ID: <48569bb2$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1213635506 77.224.139.205 (16 Jun 2008 09:58:26 -0700) Lines: 26 Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news1.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail