From stephen.hubbard@btinternet.com Sat Oct 27 21:15:58 2001 Received: from gadolinium.btinternet.com (gadolinium.btinternet.com [194.73.73.111]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f9RLFwP18957 for ; Sat, 27 Oct 2001 17:15:58 -0400 (EDT) (envelope-from stephen.hubbard@btinternet.com) Received: from [213.122.14.91] (helo=r355000075) by gadolinium.btinternet.com with smtp (Exim 3.22 #6) id 15xao6-00070T-00 for pgsql-sql@postgresql.org; Sat, 27 Oct 2001 22:15:54 +0100 Message-ID: <000801c15f2c$2ff6fcc0$5b0e7ad5@r355000075> From: "stephen" To: Subject: delete queires Date: Sat, 27 Oct 2001 22:13:10 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0005_01C15F34.904A2180" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 X-Archive-Number: 200110/383 X-Sequence-Number: 5335 This is a multi-part message in MIME format. ------=_NextPart_000_0005_01C15F34.904A2180 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable i was wondering if it's possible to make a delete query to delete only one = of the two fields in a table. I have tried only putting that field as the = "from" but it still deletes the other field also? Is there a macro or module code i could use? your help would be much appre= ciated regards Steve ------=_NextPart_000_0005_01C15F34.904A2180 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
i was wondering if it's possible to make a= delete=20 query to delete only one of the two fields in a table.  I have tried o= nly=20 putting that field as the "from" but it still deletes the other field=20 also?
 
Is there a macro or module code i could us= e? =20 your help would be much appreciated
 
regards
Steve
------=_NextPart_000_0005_01C15F34.904A2180-- From frank@wiles.org Mon Oct 29 16:45:58 2001 Received: from frank.wiles.org (frank.wiles.org [24.124.35.230]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f9TGjwP02989 for ; Mon, 29 Oct 2001 11:45:58 -0500 (EST) (envelope-from frank@frank.wiles.org) Received: (from frank@localhost) by frank.wiles.org (8.11.6/8.11.6) id f9TGoRN03729; Mon, 29 Oct 2001 10:50:27 -0600 Date: Mon, 29 Oct 2001 10:50:27 -0600 From: Frank Wiles To: stephen Cc: pgsql-sql@postgresql.org Subject: Re: delete queires Message-ID: <20011029105027.U6370@frank.wiles.org> References: <000801c15f2c$2ff6fcc0$5b0e7ad5@r355000075> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <000801c15f2c$2ff6fcc0$5b0e7ad5@r355000075>; from stephen.hubbard@btinternet.com on Sat, Oct 27, 2001 at 10:13:10PM +0100 X-Archive-Number: 200110/393 X-Sequence-Number: 5345 .------[ stephen wrote (2001/10/27 at 22:13:10) ]------ | | i was wondering if it's possible to make a delete query to delete only one | of the two fields in a table. I have tried only putting that field as | the "from" but it still deletes the other field also? | | Is there a macro or module code i could use? your help would be much | appreciated | `------------------------------------------------- No you can't delete a field, delete is only for entire rows. What you'll want to do is UPDATE the field(s) in question to NULLs. --------------------------------- Frank Wiles http://frank.wiles.org --------------------------------- From reedstrm@rice.edu Mon Oct 29 17:35:39 2001 Received: from ece.rice.edu (ece.rice.edu [128.42.4.34]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f9THZdP19171 for ; Mon, 29 Oct 2001 12:35:39 -0500 (EST) (envelope-from reedstrm@rice.edu) Received: from localhost (localhost [127.0.0.1]) by ece.rice.edu (Postfix) with ESMTP id A171068A5F for ; Mon, 29 Oct 2001 11:35:38 -0600 (CST) Received: from wallace.ece.rice.edu (wallace.ece.rice.edu [128.42.12.154]) by ece.rice.edu (Postfix) with ESMTP id B754468A5A for ; Mon, 29 Oct 2001 11:35:37 -0600 (CST) Received: from reedstrm by wallace.ece.rice.edu with local (Exim 3.22 #1 (Debian)) id 15yGK1-0005pX-00 for ; Mon, 29 Oct 2001 11:35:37 -0600 Date: Mon, 29 Oct 2001 11:35:37 -0600 From: "Ross J. Reedstrom" To: pgsql-sql@postgresql.org Subject: Re: delete queires Message-ID: <20011029113537.C21886@rice.edu> Mail-Followup-To: "Ross J. Reedstrom" , pgsql-sql@postgresql.org References: <000801c15f2c$2ff6fcc0$5b0e7ad5@r355000075> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <000801c15f2c$2ff6fcc0$5b0e7ad5@r355000075> User-Agent: Mutt/1.3.18i X-Virus-Scanned: by AMaViS snapshot-20010714 X-Archive-Number: 200110/394 X-Sequence-Number: 5346 On Sat, Oct 27, 2001 at 10:13:10PM +0100, stephen wrote: > i was wondering if it's possible to make a delete query to delete only one of the two fields in a table. I have tried only putting that field as the "from" but it still deletes the other field also? Steve, If I understand your question, you don't want a DELETE, you want an UPDATE, where you set one field to NULL (or other vaule you're using to indicate an absence of information). Examples of what you want to do are always best. Ross -- Ross Reedstrom, Ph.D. reedstrm@rice.edu Executive Director phone: 713-348-6166 Gulf Coast Consortium for Bioinformatics fax: 713-348-6182 Rice University MS-39 Houston, TX 77005 From sszabo@megazone23.bigpanda.com Mon Oct 29 17:45:58 2001 Received: from megazone.bigpanda.com ([63.150.15.178]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f9THjwP21380 for ; Mon, 29 Oct 2001 12:45:58 -0500 (EST) (envelope-from sszabo@megazone23.bigpanda.com) Received: by megazone.bigpanda.com (Postfix, from userid 1001) id EAA95D5CB; Mon, 29 Oct 2001 09:45:56 -0800 (PST) Received: from localhost (localhost [127.0.0.1]) by megazone.bigpanda.com (Postfix) with ESMTP id DE5865BD0; Mon, 29 Oct 2001 09:45:56 -0800 (PST) Date: Mon, 29 Oct 2001 09:45:56 -0800 (PST) From: Stephan Szabo To: stephen Cc: Subject: Re: delete queires In-Reply-To: <000801c15f2c$2ff6fcc0$5b0e7ad5@r355000075> Message-ID: <20011029094358.Y9662-100000@megazone23.bigpanda.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Archive-Number: 200110/398 X-Sequence-Number: 5350 On Sat, 27 Oct 2001, stephen wrote: > i was wondering if it's possible to make a delete query to delete only > one of the two fields in a table. I have tried only putting that > field as the "from" but it still deletes the other field also? AFAIK delete works on entire rows. What is it you want it to do preciselfy? If you want to set the other value to null, an update is probably really what you want.