db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r545639 - /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CollationTest.java
Date Fri, 08 Jun 2007 21:41:11 GMT
Author: mamta
Date: Fri Jun  8 14:41:10 2007
New Revision: 545639

URL: http://svn.apache.org/viewvc?view=rev&rev=545639
Log:
DERBY-2777
I realized that there are no negative test case for parameter inside XMLSERIALIZE funciton.
Adding them as part of this checkin. Parameters
are not supported inside XMLSERIALIZE and that's what the new test cases are checking. No
collation involved for parameter inside this
function because parameter inside XMLSERIALIZE will fail at compilation time.


Modified:
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CollationTest.java

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CollationTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CollationTest.java?view=diff&rev=545639&r1=545638&r2=545639
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CollationTest.java
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CollationTest.java
Fri Jun  8 14:41:10 2007
@@ -683,6 +683,14 @@
         		" xmlTable, SYS.SYSTABLES WHERE XMLSERIALIZE(x as CHAR(10)) = " + 
     			" CAST(TABLENAME AS CHAR(10))",
         		null);
+        //Do some parameter testing for XMLSERIALIZE. ? is not supported inside
+        //the XMLSERIALIZE function and hence following will result in errors.
+        checkPreparedStatementError(conn, "SELECT XMLSERIALIZE(x as CHAR(10)) " +
+        		" FROM xmlTable, SYS.SYSTABLES WHERE " +
+				" XMLSERIALIZE(? as CHAR(10)) = TABLENAME", "42Z70");
+        checkPreparedStatementError(conn, "SELECT XMLSERIALIZE(x as CHAR(10)) FROM " +
+        		" xmlTable, SYS.SYSTABLES WHERE XMLSERIALIZE(? as CHAR(10)) = " + 
+    			" CAST(TABLENAME AS CHAR(10))", "42Z70");
     }
 
     //Start of parameter testing



Mime
View raw message