Re: [SQL] LIMIT 1 FOR UPDATE or FOR UPDATE LIMIT 1?

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
Cc: magnus(dot)enbom(at)rockstorm(dot)se, Jan Wieck <JanWieck(at)Yahoo(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: [SQL] LIMIT 1 FOR UPDATE or FOR UPDATE LIMIT 1?
Date: 2002-08-28 02:45:24
Message-ID: 200208280245.g7S2jO803463@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-sql


OK, patch attached. It was actually easier than I thought. We have to
decide if we are going to remove the old syntax in 7.4.

Regression tests pass. No doc updates yet.

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

Christopher Kings-Lynne wrote:
> > OK, no one has commented on this, so I guess I am going to have to guess
> > the group's preference.
> >
> > My guess, seeing as very few probably use LIMIT and FOR UPDATE together,
> > is to swap them and document it in the release notes. Was I correct in
> > my guess?
>
> I'm sure very few people do it - but are you sure you can't just allow both
> syntaxes?
>
> Chris
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/users-lounge/docs/faq.html
>

--
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

Attachment Content-Type Size
unknown_filename text/plain 3.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2002-08-28 03:00:58 Re: fix for palloc() of user-supplied length
Previous Message Gavin Sherry 2002-08-28 01:59:40 Re: Proposed GUC Variable

Browse pgsql-sql by date

  From Date Subject
Next Message Josh Berkus 2002-08-28 03:30:32 Calculation Error on Epoch?
Previous Message Christopher Kings-Lynne 2002-08-28 01:45:55 Re: LIMIT 1 FOR UPDATE or FOR UPDATE LIMIT 1?