| From: | markw(at)osdl(dot)org |
|---|---|
| To: | mendola(at)bigfoot(dot)com |
| Cc: | pgsql-hackers(at)postgresql(dot)org, osdldbt-general(at)lists(dot)sourceforge(dot)net |
| Subject: | Re: Is this a commit problem? |
| Date: | 2003-09-25 17:00:02 |
| Message-ID: | 200309251700.h8PH05132125@mail.osdl.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On 25 Sep, Gaetano Mendola wrote:
> markw(at)osdl(dot)org wrote:
>
>> 2. SELECT d_next_o_id
>> INTO current_o_id
>> FROM district
>> WHERE d_w_id = 1
>> AND d_id = 8
>>
>> 3. UPDATE district
>> SET d_next_o_id = d_next_o_id + 1
>> WHERE d_w_id = 1
>> AND d_id = 8
>
> I don't know exactly what you are trying to do
> but usualy in cases like this, in order to avoid
> further problem in the commit phase you ought to
> do a SELECT .... FOR UPDATE instead.
That appears to have done the trick. Thanks!
Mark
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tom Lane | 2003-09-25 17:03:02 | Re: [HACKERS] Threads vs Processes |
| Previous Message | Bruce Momjian | 2003-09-25 16:57:09 | Re: [HACKERS] Threads vs Processes (was: NuSphere and PostgreSQL for |