Given the query:
[...]
declare variable $ext as xs:integer external := 0;
[...]
for
xqxq:bind-variable( $queryID, xs:QName("ext"), "5");
I'm guessing that in XQXQ, at this moment you do something like this:
- if the passed type is the same as the type of the variable => bind the value; Otherwise raise an error.
The new functionality I was mentioning would do something like this:
If the type of the given value (xs:string in this case) can be casted to the type of the variable (xs:integer) then cast the value and bind it to the variable. Otherwise raise an error.
Given the query:
[...]
declare variable $ext as xs:integer external := 0;
[...]
for
xqxq:bind-variable( $queryID, xs:QName("ext"), "5");
I'm guessing that in XQXQ, at this moment you do something like this:
- if the passed type is the same as the type of the variable => bind the value; Otherwise raise an error.
The new functionality I was mentioning would do something like this:
If the type of the given value (xs:string in this case) can be casted to the type of the variable (xs:integer) then cast the value and bind it to the variable. Otherwise raise an error.