>
> [FORG0001] Cannot convert xs:string to xs:anyURI: "
> HTtpS://reGexr.com/more/less/path/foo.p
>
Your URI string contains invalid characters. The first query yields a
result, the second doesn’t:
xs:anyURI("[")
xs:anyURI("%5b")
There are various ways to get this cleaned up. For
So, I just came around this:
declare variable $local:uri as xs:anyURI := xs:anyURI("
HTtpS://reGexr.com/more/less/path/foo.php?q=bar[12]=xxx[11]=#sldns13123nfdwdw
");
$local:uri
The error I get is
[XPST0003] Invalid entity: '[12]=xxx[1...'.
so I encoded the '&' to ''.
declare variable
On Mon, Aug 13, 2018 at 7:25 PM Christian Grün
wrote:
> https://www.w3.org/TR/xquery-31/#id-function-conversion-rules
> https://www.w3.org/TR/xquery-31/#promotion
>
Thanks for the links. Will check.
> Me too, because the following query works on my environment:
>
> declare variable
Is it not the case that because xs:anyURI is derived from xs:string, you
can always go "up" the derivation, because the derived type is less general
and always remains an instance of the more general type, but the more
general type (casting "down" the path of derivation) is not necessarily an
> whenever I define the type of a parameter as xs:anyURI and pass a string
to it, I get the error "Cannot convert xs:string to xs:anyURI".
It might comfort you to hear that the behavior is indeed compliant with the
spec. As it would take some time to recite the reasons for this, feel free
to scan
I should have added, that this also does not succeed:
declare variable $local:uri1 as xs:anyURI := xs:anyURI("
http://example.com/batz/mongo/blah/index.html;);
which leaves me even more baffled.
--
Minden jót, all the best, Alles Gute,
Andreas Mixich
Hi,
whenever I define the type of a parameter as xs:anyURI and pass a string to
it, I get the error "Cannot convert xs:string to xs:anyURI". I am aware,
that xs:anyURI gets automatically cast to xs:string, whenever needed. But
why not the other way around? Especially, since in the hierarchy of
7 matches
Mail list logo