Re: minimal update - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: minimal update
Date
Msg-id 47387926.9050305@dunslane.net
Whole thread Raw
In response to Re: minimal update  (Decibel! <decibel@decibel.org>)
List pgsql-hackers

Decibel! wrote:
> On Nov 2, 2007, at 10:49 AM, Andrew Dunstan wrote:
>>    update tname set foo = bar ... where foo is null or foo <> bar ...
>
> FYI, you should be able to do WHERE foo IS DISTINCT FROM bar instead.

True, that's a bit nicer. It's still more than somewhat ugly and fragile 
if there a lot of foos and the bars are complex expressions.

cheers

andrew


pgsql-hackers by date:

Previous
From: Decibel!
Date:
Subject: Re: minimal update
Next
From: Alvaro Herrera
Date:
Subject: Re: [hibernate-team] PostgreSQLDialect