Re: BUG #1517: SQL interval syntax is accepted by the parser,

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Roy Badami <roy(at)gnomon(dot)org(dot)uk>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #1517: SQL interval syntax is accepted by the parser,
Date: 2005-03-23 20:31:09
Message-ID: 200503232031.j2NKV9p06238@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Roy Badami wrote:
>
> Bruce> * Interpret INTERVAL '1:30' MINUTE TO SECOND as '1
> Bruce> minute 30 seconds'
>
> This seems redundant; it's just another example of the ANSI day-time
> interval syntax...

The reason I added it is that usually people think of the PG syntax as
'1 hour 30 seconds'. The '1:30' is a kind of subtle because both PG and
ANSI support that syntax and we need to handle that. The tricky part is
that we can't say by looking at '1:30' whether it is PG or ANSI, and
that will affect how we deal with the clause after it.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Roy Badami 2005-03-23 20:41:07 Re: BUG #1517: SQL interval syntax is accepted by the parser,
Previous Message Joel Krajden 2005-03-23 20:22:30 foreign key constraint not working when index tablespace is not default.