Hi, I'm trying to do something with dates which is proving to be a bit
tricky.

I'm trying to get the current "date" and add 3 days to this.


I've tried:

$date = "(now::date) + ('3 days'::interval)";

DBD::Pg::st execute failed: ERROR: parser: parse error at or near "3"


... and : 

$date = "(now::date) + (\\'3 days\\'::timespan)";

DBD::Pg::st execute failed: ERROR: Bad date external representation
'(now::date) + ('3 days'::timespan)'

Needless to say I'm using this date creation string as a parameter of a
DBD::Pg CGI query, hence further complications with apostrophes.

I've found nothing concrete in the documentation about how to do this, and
the closest thing to an answer came from this newsgroup. No luck so far
tho'

does anyone know how to do this and possibly and source of good
documentation on this type of thing.

Regards

Scott McDaid
edNET
t: +44 131 625 5557 (direct dial)
t: +44 131 466 7003 (office)

Reply via email to