Re: Update PK Violation - Mailing list pgsql-sql

From Achilleas Mantzios
Subject Re: Update PK Violation
Date
Msg-id 200801161630.15623.achill@matrix.gatewaynet.com
Whole thread Raw
In response to Update PK Violation  (Franklin Haut <franklin.haut@gmail.com>)
Responses Re: Update PK Violation  ("Scott Marlowe" <scott.marlowe@gmail.com>)
List pgsql-sql
Στις Tuesday 15 January 2008 23:03:49 ο/η Franklin Haut έγραψε:
> Hi all,
>
> i have a problem with one update sentence sql.
>

A simple way i use:

foodb=# update temp set num = num*1000  where num >= 5;
foodb=# insert into temp values (5, 'NOT');
foodb=# update temp set num = 1 + num/1000  where num >= 6;

--
Achilleas Mantzios


pgsql-sql by date:

Previous
From: "Fernando Hevia"
Date:
Subject: Re: Update PK Violation
Next
From: Bryan Emrys
Date:
Subject: Re: SQL dealing with subquery