From fc568b9d8f6b30d0a5573b73c719e23fa0a6a979 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut <peter_e@gmx.net>
Date: Fri, 12 Jan 2007 16:29:24 +0000
Subject: Allow for arbitrary data types as content in XMLELEMENT.  The
 original coercion to type xml was a mistake.  Escape values so they are valid
 XML character data.

---
 src/test/regress/sql/xml.sql | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

(limited to 'src/test/regress/sql/xml.sql')

diff --git a/src/test/regress/sql/xml.sql b/src/test/regress/sql/xml.sql
index d3a1e6104bb..a22c8251298 100644
--- a/src/test/regress/sql/xml.sql
+++ b/src/test/regress/sql/xml.sql
@@ -37,9 +37,15 @@ SELECT xmlelement(name element, xmlelement(name nested, 'stuff'));
 
 SELECT xmlelement(name employee, xmlforest(name, age, salary as pay)) FROM emp;
 
-SELECT xmlelement(name wrong, 37);
 SELECT xmlelement(name duplicate, xmlattributes(1 as a, 2 as b, 3 as a));
 
+SELECT xmlelement(name num, 37);
+SELECT xmlelement(name foo, text 'bar');
+SELECT xmlelement(name foo, xml 'bar');
+SELECT xmlelement(name foo, text 'b<a/>r');
+SELECT xmlelement(name foo, xml 'b<a/>r');
+SELECT xmlelement(name foo, array[1, 2, 3]);
+
 
 SELECT xmlparse(content 'abc');
 SELECT xmlparse(content '<abc>x</abc>');
-- 
cgit v1.2.3

