1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-17 17:02:08 +03:00

Make casts from xml to text independent of the XML option setting, thus

immutable and indexable.  Also fix the volatility settings of some other
XML-related functions.
This commit is contained in:
Peter Eisentraut
2007-11-27 12:21:05 +00:00
parent 542d04e179
commit 7888b52076
6 changed files with 24 additions and 13 deletions

View File

@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $PostgreSQL: pgsql/src/backend/utils/adt/xml.c,v 1.60 2007/11/25 12:08:11 petere Exp $
* $PostgreSQL: pgsql/src/backend/utils/adt/xml.c,v 1.61 2007/11/27 12:21:05 petere Exp $
*
*-------------------------------------------------------------------------
*/
@ -535,7 +535,8 @@ xmltotext(PG_FUNCTION_ARGS)
{
xmltype *data = PG_GETARG_XML_P(0);
PG_RETURN_TEXT_P(xmltotext_with_xmloption(data, xmloption));
/* It's actually binary compatible. */
return (text *) data;
}