Closed jonleopard closed 1 year ago
interval $3::interval
The interval '..'
syntax is not specific to intervals, and only works when followed by a string literal. Simply now() at time zone 'utc' + $3::interval
will work here. (Though you might want to consider whether you really want to use timestamp without time zone
at all.)
Fixed! Thank you so much! Regarding your comment on timestamp without time zone
, is defining a TZ generally a best practice? If so, set it to the TZ of the host?
The query below throws the following error:
pq: syntax error at or near "$3"
I'm still getting my PostgreSQL ropes so I apologize if there is something obvious that I'm missing. Any help would be greatly appreciated!