Thanks to visit codestin.com
Credit goes to postgrespro.com

Re: Please advise features in 7.1 (SUMMARY) - Mailing list pgsql-hackers

From Andrew Snow
Subject Re: Please advise features in 7.1 (SUMMARY)
Date
Msg-id [email protected]
Whole thread Raw
In response to Re: Please advise features in 7.1 (SUMMARY)  (Thomas Lockhart <[email protected]>)
List pgsql-hackers
On Thu, 30 Nov 2000, Thomas Lockhart wrote:

> > Is "if" clause support in PG?
> > for example:
> > "drop table aa if exist"
> > "insert into aa values(1) if not exists select * from aa where i=1"
> 
> No. afaict it is not in any SQL standard, so is unlikely to get much
> attention from developers.

Plus, for that second one can't you just do:

INSERT INTO aa SELECT 1 WHERE NOT EXISTS (SELECT * FROM aa WHERE i=1);


- Andrew




pgsql-hackers by date:

Previous
From: Thomas Lockhart
Date:
Subject: Re: Please advise features in 7.1 (SUMMARY)
Next
From: Manish Vig
Date:
Subject: