Hi Reece, Have you tried with a more regular qname? The docs give ‘validate as xs:boolean’ as example, not URIQualifiedName:
http://docs.marklogic.com/guide/xquery/langoverview#id_55039 Keep in mind that MarkLogic does not cover the full XQuery 3 recommendation.. Cheers, Geert From: <general-boun...@developer.marklogic.com<mailto:general-boun...@developer.marklogic.com>> on behalf of Reece Dunn <mscl...@googlemail.com<mailto:mscl...@googlemail.com>> Reply-To: MarkLogic Developer Discussion <general@developer.marklogic.com<mailto:general@developer.marklogic.com>> Date: Sunday, September 25, 2016 at 1:24 PM To: "general@developer.marklogic.com<mailto:general@developer.marklogic.com>" <general@developer.marklogic.com<mailto:general@developer.marklogic.com>> Subject: [MarkLogic Dev General] The validate as/type construct does not support URIQualifiedName Hi all, I have found an issue in the MarkLogic support for XQuery 3.0 'validate type' constructs on MarkLogic 6.0 - 8.0 (https://www.w3.org/TR/2014/REC-xquery-30-20140408/#prod-xquery30-ValidateExpr). Given: xquery version "1.0-ml"; validate as Q{a}b { <test/> } MarkLogic reports a parser error ("[1.0-ml] XDMP-UNEXPECTED: (err:XPST0003) Unexpected token syntax error, unexpected URIQualifiedName_"). It is valid to have a URIQualifiedName here according to the XQuery 3.0 grammar: [101] ValidateExpr<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#doc-xquery30-ValidateExpr> ::= "validate" (ValidationMode<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#prod-xquery30-ValidationMode> | ("type" TypeName<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#prod-xquery30-TypeName>))? "{" Expr<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#prod-xquery30-Expr> "}" [190] TypeName<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#doc-xquery30-TypeName> ::= EQName<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#prod-xquery30-EQName> [196] EQName<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#doc-xquery30-EQName> ::= QName<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#prod-xquery30-QName> | URIQualifiedName<https://www.w3.org/TR/2014/REC-xquery-30-20140408/#prod-xquery30-URIQualifiedName> This also affects the MarkLogic specific 'validate as' syntax. Kind regards, Reece
_______________________________________________ General mailing list General@developer.marklogic.com Manage your subscription at: http://developer.marklogic.com/mailman/listinfo/general