Re: Table alias in DELETE statements

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Hanno Wiegard <hwiegard(at)voiceobjects(dot)com>
Cc: chriskl(at)familyhealth(dot)com(dot)au, pgsql-sql(at)postgresql(dot)org
Subject: Re: Table alias in DELETE statements
Date: 2002-09-16 19:50:12
Message-ID: 200209161950.g8GJoCn08723@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


More long term, if you read the link attached to the TODO item. There is
a question of how to cleanly implement it.

---------------------------------------------------------------------------

Hanno Wiegard wrote:
> Good, but is the implementation of this feature a short-term goal or
> more long-term?
>
> Thanks,
> hanno
>
> -----Original Message-----
> From: Bruce Momjian [mailto:pgman(at)candle(dot)pha(dot)pa(dot)us]
> Sent: Montag, 16. September 2002 06:04
> To: Christopher Kings-Lynne
> Cc: Hanno Wiegard; pgsql-sql(at)postgresql(dot)org
> Subject: Re: [SQL] Table alias in DELETE statements
>
>
>
> TODO has:
>
> * Allow DELETE to handle table aliases for self-joins [delete]
>
> ------------------------------------------------------------------------
> ---
>
> Christopher Kings-Lynne wrote:
> > On the several occasions I've tried using table aliases in delete
> > statements, it hasn't worked.
> >
> > Chris
> >
> > On Fri, 13 Sep 2002, Hanno Wiegard wrote:
> >
> > > Hi,
> > >
> > > I've already checked the mailing archive but found nothing about
> > > problems with the DELETE statement and table alias but it's not
> > > mentioned in the docs. So the question for me is whether it is
> possible
> > > to use a table alias in a DELETE statement or not, e.g.
> > > DELETE FROM foo f WHERE f.ID > 3000 (more complicated cases in
> reality
> > > and I really need the alias because the SQL is generated
> automaically
> > > by a tool)?
> > >
> > > Thanks,
> > > Hanno Wiegard
> > >
> > >
> > >
> > >
> ________________________________________________________________________
> ______
> > > Die clevere Geldreserve: der DiBa-Privatkredit. Funktioniert wie ein
> Dispo,
> > > ist aber viel gunstiger! Alle Infos: http://diba.web.de/?mc=021104
> > >
> > >
> > > ---------------------------(end of
> broadcast)---------------------------
> > > TIP 4: Don't 'kill -9' the postmaster
> > >
> >
> >
> > ---------------------------(end of
> broadcast)---------------------------
> > TIP 6: Have you searched our list archives?
> >
> > http://archives.postgresql.org
> >
>
> --
> Bruce Momjian | http://candle.pha.pa.us
> pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
> + If your life is a hard drive, | 13 Roberts Road
> + Christ can be your backup. | Newtown Square, Pennsylvania
> 19073
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
> message can get through to the mailing list cleanly
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

Browse pgsql-sql by date

  From Date Subject
Next Message Christopher Kings-Lynne 2002-09-17 01:28:31 Re: does table names have a format and size
Previous Message Ngan Duong 2002-09-16 17:04:02 please delete my email address from your list