Closed kfigiela closed 1 month ago
Love it. Good and solid functionality to be added. Thank you.
Any chance you can add a test file that confirms its working (so we detect if we break that later)?
Is .jsonl
the right name? What about .ndjson
(new line delimited json) or I have even seen .jsons
?
@kfigiela ?
@mathiasrw, thanks for reminder. I'll try to address those over the weekend and add tests.
As far as the extension/naming, according to a blog post these are "competing", but practically identical standards. We only parse, so as long as JSON.parse can handle it we should be good. I think, it makes sense to register them both, so either file extension works.
https://duckdb.org/2023/03/03/json.html uses ndjson indeed, would be good to rename.
On the other hand, Google BigQuery mentions JSONL everywhere. Nevertheless, we can have both aliases working and this is what I have implemented. Otherwise, I addressed the above comments and added some tests.
Just provide all the most used names (alasql.jsonl = alasql.ndjson = alsql.....)
Ahh - you already did :)
JSON support is great, but JSONL is very common in streaming cases (e.g. logs).