From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Bernd Helmle <mailings(at)oopsware(dot)de> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Error message and infinite date and timestamp conversion in XML |
Date: | 2009-03-27 18:59:23 |
Message-ID: | 2529.1238180363@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Bernd Helmle <mailings(at)oopsware(dot)de> writes:
> map_sql_value_to_xml_value() currently errors out with a more or less vague
> error message, when a date or timestamp datatype with an infinite value is
> converted to XML. This is likely to create some confusion, especially when
> you have to debug some complex procedures and involved XML conversions. I
> propose to add the attached DETAIL to this error message, so people will
> get an idea what's currently going wrong.
Done, but I noticed while testing that it's not real consistent:
regression=# select xmlelement(name foo, 'infinity'::timestamp);
ERROR: timestamp out of range
DETAIL: XML does not support infinite timestamp values.
regression=# select xmlelement(name foo, xmlattributes('infinity'::timestamp as bar));
xmlelement
-----------------------
<foo bar="infinity"/>
(1 row)
Should we consider doing something about that, or is it okay as-is?
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2009-03-27 19:04:08 | Re: Any reason not to return row_count in cursor of plpgsql? |
Previous Message | Tom Lane | 2009-03-27 18:06:28 | Re: 8.4 open items list |