Re: Curosity question regarding "LOCK" NOWAIT

From: David Johnston <polobo(at)yahoo(dot)com>
To: John R Pierce <pierce(at)hogranch(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Curosity question regarding "LOCK" NOWAIT
Date: 2012-09-22 04:35:18
Message-ID: 6A5B0E96-A4E5-43FE-889A-298F523EF518@yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sep 22, 2012, at 0:08, John R Pierce <pierce(at)hogranch(dot)com> wrote:

> On 09/21/12 7:43 PM, David Johnston wrote:
>> Has there been any discussion regarding adding a time-limited version of NOWAIT, say: “WAITONLY 50” (milliseconds), when dealing the explicit LOCK TABLE or the SELECT…FOR(SHARE|UPDATE) commands?
>
> is this a feature in any other major databases?

Doesn't matter to me...I'm only using PostgreSQL
>
> is this in the sql spec?
>

Guessing no if it is not implemented...

> what do you expect to happen if these timeouts expire? return an error, and abort the transaction?
>

The same thing that happens if "NOWAIT" had been specified instead.

The goal is to specify that I don't mind waiting but only for a short period of time.

David J.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Jasen Betts 2012-09-22 05:33:22 Re: On Ubuntu 12.04 i do have two psql one of those isn't working
Previous Message Chris Travers 2012-09-22 04:11:25 Question about upgrading extensions