Re: BUG #5028: CASE returns ELSE value always when type is"char" - Mailing list pgsql-bugs

From Sam Mason
Subject Re: BUG #5028: CASE returns ELSE value always when type is"char"
Date
Msg-id 20090902190819.GZ5407@samason.me.uk
Whole thread Raw
In response to Re: BUG #5028: CASE returns ELSE value always when type is"char"  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Responses Re: BUG #5028: CASE returns ELSE value always when type is"char"  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
List pgsql-bugs
On Wed, Sep 02, 2009 at 01:37:20PM -0500, Kevin Grittner wrote:
> That still seems to be the case in the draft of the 2003 standard I
> have:
>
> <general literal> ::=
>     <character string literal>
>   | <national character string literal>
>   | <Unicode character string literal>
>   | <binary string literal>
>   | <datetime literal>
>   | <interval literal>
>   | <boolean literal>
> <character string literal> ::=
>     [ <introducer><character set specification> ]
>     <quote> [ <character representation>... ] <quote>
>     [ { <separator> <quote> [ <character representation>... ] <quote>
> }... ]
>
> The ball's in your court to show something in the standard to say that
> a character string literal is ever *not* to be taken as a character
> string.

Huh, you're right.  I'd always thought '2001-01-01' was a valid date
literal, seems the standard has required it to be prefixed by DATE at
least back to SQL92.

--
  Sam  http://samason.me.uk/

pgsql-bugs by date:

Previous
From: Sam Mason
Date:
Subject: Re: BUG #5028: CASE returns ELSE value always when type is"char"
Next
From: Sam Mason
Date:
Subject: Re: BUG #5028: CASE returns ELSE value always when type is"char"