Re: Handling NULL records in plpgsql

From: "Robert Haas" <robertmhaas(at)gmail(dot)com>
To: Decibel! <decibel(at)decibel(dot)org>
Cc: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Postgres Hackers" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Handling NULL records in plpgsql
Date: 2008-10-25 18:59:07
Message-ID: 603c8f070810251159s2948f337g380e5c9e2b73352c@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> I really think we should have a way of telling if a array/row/record
> variable is actually set to something, and I'm pretty sure that should be
> unrelated to whether all the elements in it happen to be null.

+1. Also, can whatever syntax we introduce by something relatively
concise? Code that looks nice when you write "=" does not look as
nice when you write "IS NOT DISTINCT FROM". I'm almost inclined to
suggest using functional notation rather than dreaming up a new "IS
WHATEVER" syntax.

> And the IS
> NOT NULL case seems exceptionally broken. I think it's extremely confusing
> to have it behave differently than NOT blah IS NULL.

-1. This is obviously a trap for the unwary but I think we're stuck with it.

...Robert

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dave Gudeman 2008-10-25 20:35:35 Re: Handling NULL records in plpgsql
Previous Message Robert Haas 2008-10-25 18:31:06 Re: Regression in IN( field, field, field ) performance