| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Joshua Kramer <josh(at)globalherald(dot)net> |
| Cc: | pgsql-novice(at)postgresql(dot)org |
| Subject: | Re: Odd Timestamp Error WAS Re: Function Creation Error |
| Date: | 2007-04-08 14:56:38 |
| Message-ID: | 7030.1176044198@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-novice |
Joshua Kramer <josh(at)globalherald(dot)net> writes:
> LOG: statement: INSERT INTO auth_tickets (user_id,
> expire_datetime, init_datetime, init_ip_addr, ticket_serial) VALUES ('2',
> 'now() + 6 * interval ''1 hour''', 'now()', '192.168.2.2',
> '44d6e7d4b2e87632a65cd34501aeea614bffde5f')
> ERROR: invalid input syntax for type timestamp: "now() + 6 * interval '1
> hour'"
You seem to be confused about the difference between a literal constant
and an expression. That should just be
LOG: statement: INSERT INTO auth_tickets (user_id,
expire_datetime, init_datetime, init_ip_addr, ticket_serial) VALUES ('2',
now() + 6 * interval '1 hour', now(), '192.168.2.2',
'44d6e7d4b2e87632a65cd34501aeea614bffde5f')
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Joshua Kramer | 2007-04-08 19:22:43 | Re: Odd Timestamp Error WAS Re: Function Creation Error |
| Previous Message | Joshua Kramer | 2007-04-08 08:58:53 | Odd Timestamp Error WAS Re: Function Creation Error |