RumbleDB/rumble

Document or implement passing integer values into external variables

ingomueller-net opened this issue · 2 comments

It should be possible to pass in a value to $i in the following query:

declare variable $i as integer external := 0; $i

However, using the flag --variable:i 42 results in the following error:

⚠️  ️There was an error.

Code: [XPTY0004] (this code can be looked up in the documentation and specifications).

Location information: file:/home/muellein/git/Rumble/external.jq:LINE:1:COLUMN:0:

External variable value (42) does not match the expected type (xs:integer).

Is there a trick or is this currently not supported?

Thanks, Ingo. I think for now it always considers the input as a string (except for anyURI that it resolves to a path). I need to add an automatic cast.

@ingomueller-net do you agree if we close this issue?