From: Paul K. <pa...@xm...> - 2011-05-25 04:12:46
|
I'm having a great deal of difficulty with some client xml. The error I'm getting has nothing to do with transformer (xalan and saxon produce same result; running just the transform in oXygen works on all processors). Here it is (full output and system info pasted below): Caused by: java.net.URISyntaxException: Illegal character in path at index 5: Major League Lacrosse If you remove "Major League Lacrosse" from <pstrk:leaguename>. But that's valid according to the xsd, so that's not the cause. Seems something deeper? Simplified debug code as follows: ****** Xquery ********* xquery version "1.0"; declare namespace pstrk="http://www.pointstreak.com/xml/schema/statsdata-v1"; let $pstrk2sml := "/db/simple.xsl" let $pstrk-doc := <pstrk:schedule xmlns="http://www.pointstreak.com/xml/schema/statsdata-v1" xmlns:pstrk="http://www.pointstreak.com/xml/schema/statsdata-v1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.pointstreak.com/ http://www.pointstreak.com/xml/schema/statsdata-v1.xsd" timestamp="2011-05-24T14:34:10-07:00" type="League Schedule"> <pstrk:league leagueid="323"> <pstrk:leaguename>Major League Lacrosse</pstrk:leaguename> </pstrk:league> </pstrk:schedule> return transform:transform(doc($pstrk-doc),doc($pstrk2sml),<parameters><param name="exist:stop-on-error" value="no"/></parameters>) *********** XSL (simple.xsl) ************ <?xml version="1.0" encoding="UTF-8"?> <pstrk:schedule xmlns="http://www.pointstreak.com/xml/schema/statsdata-v1" xmlns:pstrk="http://www.pointstreak.com/xml/schema/statsdata-v1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.pointstreak.com/ http://www.pointstreak.com/xml/schema/statsdata-v1.xsd" timestamp="2011-05-24T14:34:10-07:00" type="League Schedule"> <pstrk:league leagueid="323"> </pstrk:league> </pstrk:schedule> ******** Error Stack ************ Caused by: org.exist.xquery.XPathException: at org.exist.xquery.util.DocUtils.getDocumentByPath(DocUtils.java:184) at org.exist.xquery.util.DocUtils.getDocument(DocUtils.java:67) at org.exist.xquery.functions.FunDoc.eval(FunDoc.java:108) ... 39 more Caused by: java.net.URISyntaxException: Illegal character in path at index 5: Major League Lacrosse at java.net.URI$Parser.fail(URI.java:2825) at java.net.URI$Parser.checkChars(URI.java:2998) at java.net.URI$Parser.parseHierarchical(URI.java:3082) at java.net.URI$Parser.parse(URI.java:3040) at java.net.URI.<init>(URI.java:595) at org.exist.xmldb.XmldbURI.xmldbUriFor(XmldbURI.java:98) at org.exist.xquery.util.DocUtils.getDocumentByPath(DocUtils.java:152) ... 41 more ********* System ******** System Status General eXist Version: 1.4.0rc eXist Build: 20090908 eXist Home: /opt/exist SVN Revision: 10028 Operating System: Linux 2.6.35-28-virtual amd64 File encoding: UTF-8 Java Vendor: Sun Microsystems Inc. Version: 1.6.0_20 Implementation: OpenJDK 64-Bit Server VM Installation: /usr/lib/jvm/java-6-openjdk/jre Memory Usage Max. Memory: 466048K Current Total: 198400K Free: 104673K |