Well, the way I've always constructed these queries is:
select period_start + interval '1 hour' from periods;
Try that. In fact, I believe the above is the correct SQL standard syntax?
Chris
> -----Original Message-----
> From: pgsql-hackers-owner@postgresql.org
> [mailto:pgsql-hackers-owner@postgresql.org]On Behalf Of Barry Lind
> Sent: Friday, 16 November 2001 9:52 AM
> To: pgsql-general@postgresql.org
> Cc: PostgreSQL-development
> Subject: [HACKERS] bug or change in functionality in 7.2?
>
>
> I have in my code a SQL statement that does the following:
>
> select period_start + interval('1 hour') from periods;
>
> This worked in 7.1, but in 7.2 I am getting the following error:
>
> ERROR: parser: parse error at or near "'"
>
> If I remove the quotes then I get the following error:
>
> ERROR: parser: parse error at or near "hour"
>
> Was this change from 7.1 to 7.2 intentional? If so, how should this be
> coded in 7.2?
>
> thanks,
> --Barry
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: Have you searched our list archives?
>
> http://archives.postgresql.org
>