"Peter Gibbs" <peter@emkel.co.za> writes:
> select to_char(now()+'3 days'::interval,'YYYY-MM-DDTHH24:MI:SS');
> to_char
> -----------------------
> 2002-12-22NDH24:41:58
Oh, duh --- "TH" is a format modifier. That's what's confusing it
(and today being the 19TH is what's confusing us).
So the suggestion of ... DD"T"HH ... is the way to go.
regards, tom lane