Re: BUG #5028: CASE returns ELSE value always when type is"char"

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: <pgsql-bugs(at)postgresql(dot)org>,"Sam Mason" <sam(at)samason(dot)me(dot)uk>
Subject: Re: BUG #5028: CASE returns ELSE value always when type is"char"
Date: 2009-09-02 19:59:54
Message-ID: 4A9E886A020000250002A94F@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Sam Mason <sam(at)samason(dot)me(dot)uk> wrote:

> CREATE VIEW v (c) AS
> SELECT NULL;
>
> PG allows it, but the resulting view seems somewhat unusable.

I'm not sure whether the only place the standard doesn't require a
cast is on assignment, but this is one place that the standard clearly
does require a cast, and I'm all for that. Requiring a cast anywhere
else the standard requires it would not offend me; although not
requiring it anywhere it doesn't generate nonstandard results, and
where the semantics are relatively sane, wouldn't offend me, either.

-Kevin

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Sam Mason 2009-09-02 20:04:26 Re: BUG #5028: CASE returns ELSE value always when type is"char"
Previous Message Kevin Grittner 2009-09-02 19:41:32 Re: BUG #5028: CASE returns ELSE value always when type is"char"