Update of /cvsroot/monetdb/sql/src/test/xml
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv14293
Modified Files:
docload.sql publish.sql
Added Files:
serialize.sql
Log Message:
Another publishing example
Index: publish.sql
===================================================================
RCS file: /cvsroot/monetdb/sql/src/test/xml/publish.sql,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- publish.sql 19 Aug 2007 11:35:19 -0000 1.2
+++ publish.sql 20 Aug 2007 06:08:38 -0000 1.3
@@ -8,6 +8,8 @@
-- SQL code snippet
-- _15 := sql.resultSet(1,1,_14);
-- sql.rsColumn(_15,"sys.","concat_concat_name","clob",1,0,_14);
+-- sql.exportResult(_15,"");
+
-- SQL/XML code snippet
-- _98 := xml.element("victim",_14);
@@ -69,3 +71,7 @@
xmlelement(name="total", (select count(*) from victim))
))
from victim V;
+
+-- escape to XQuery
+select xmlgen(<person id="{$name"} dob="{$dob}"</person>)
+from victim;
--- NEW FILE: serialize.sql ---
select xmlserialize( document,
xmlroot(
xmlforest(
xmlelement(name="id", V.name) as string,
xmlcomment( "a real victim")
),
version "versioninfo",
standalone no value
) )
from victim V;
Index: docload.sql
===================================================================
RCS file: /cvsroot/monetdb/sql/src/test/xml/docload.sql,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- docload.sql 19 Aug 2007 11:35:18 -0000 1.2
+++ docload.sql 20 Aug 2007 06:08:38 -0000 1.3
@@ -1,10 +1,14 @@
-- The Jack The Ripper case is used in different shredding formats
-- as the basis for functional testing the SQL/XML features or MonetDB
+-- check against standard!
-create table archive( doc xml ); -- to contain 1 tuple with complete document
+create table archive1( doc xml );
+create table archive2( doc xml document );
+create table archive3( doc xml sequence );
-copy into archive from 'JackTheRipper.xml';
+copy into archive1 from 'JackTheRipper.xml';
+insert into archive2 values(XMLparse( document 'JackTheRipper.xml'));
insert into archive values(XMLvalidate( document 'JackTheRipper.xml'));
create table chapters( scene xml); -- to contain a tuple per scene (18)
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Monetdb-sql-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-sql-checkins