News for hackers. Stuff that matters.
Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by gchamonlive on Wednesday June 12, 2024 @06:31AM (#40656514)
For numeric values only, any advantage of using sqlite over let's say parquet with Apache Arrow/duckdb?
Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by avereveard on Wednesday June 12, 2024 @07:30AM (#40656856)
SQLite let's you decide when and if vacuuming after partial row modifications. Does arrow allows that I don't know but it's most likely the best SQLite feature you can open a massive database and do one value change really really fast without having to write and compact the entire thing all the times.
Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by andyferris on Wednesday June 12, 2024 @07:42AM (#40656935)
Arrow isn’t great at random insertion and deletion, as each column is a contiguous array. If it’s on disk those arrays are probably packed tightly together, so you can’t even append rows.

(I have an idea to implement an LSM tree where each layer is an arrow file, which should allow for faster mutations while maintaining a lot of the benefits of arrow. But I haven’t got around to it).

Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by CJefferson on Wednesday June 12, 2024 @07:46AM (#40656961)
Given SQLite is already distributed on basically every OS,is amazingly rock solid, I’d ask instead any advantage to using Apache Arrow/duckdb? I don’t have great experience with either.
Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by jitl on Wednesday June 12, 2024 @09:22AM (#40657859)
DuckDB can have massive performance advantage over SQLite for things like aggregates on wide tables or or filters on unindexed columns, with advantage growing with the size of the table. We tried a few head to heads between the two and while we ultimately went with SQLite, we may go back and double write everything to DuckDB to get better performance for those kinds of queries on the same data set.

Duckdb can also read / import SQLite natively so we could ingest lazily from sqlite disk -> duckdb.

Biggest issue with duckdb is some memory leaks and crashes for the nodejs driver. Seems not production ready.

Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by datadrivenangel on Wednesday June 12, 2024 @03:30PM (#40662007)
They did just release DuckDB version 1.0, so it should be getting much more reliable and stable.
Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by jitl on Thursday June 13, 2024 @07:09AM (#40668120)
They said 1.0 means “we aren’t going to break the disk format backwards compatibility anymore” other than that, it’s just a number and doesn’t have any power to make the software more reliable. It really depends on their priorities how much they’ll actually stabilize my use-case. I’ll probably check back in a year and see if things improved.
Re:Why SQLite Is Taking over with Brian Holt and Marco Bambini by prirun on Wednesday June 12, 2024 @09:52AM (#40658165)
SQLite encodes integers in a variable-length format, so it can be very space-efficient compared to always storing integers in 4 or 8 bytes.