RumbleDB / rumble

⛈️ RumbleDB 1.21.0 "Hawthorn blossom" 🌳 for Apache Spark | Run queries on your large-scale, messy JSON-like data (JSON, text, CSV, Parquet, ROOT, AVRO, SVM...) | No install required (just a jar to download) | Declarative Machine Learning and more
http://rumbledb.org/
Other
211 stars 82 forks source link

"An error has occured" selection clause #1248

Open bhornerETHZ opened 8 months ago

bhornerETHZ commented 8 months ago

Working in the BD lecture cheatsheet 2023 HS' ipynb on the github dataset, I came across an error that I was told to report.

count(distinct-values(json-file("git-archive.json", 10).payload[$$.head eq $$[0].sha]))

Background: I wanted to find the number of events for which the payload head equals to the SHA of the first commit in the payload.

ghislainfourny commented 1 day ago

Thank @bhornerETHZ for the feedback. Indeed the [0] seems to lead to an error. JSONiq starts counting at 1, however there should not be an error, it should just silently return an empty sequence.