Live data from Hacker News

We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

beets.io

41–50 of 125 posts

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#41
post #4

Related note: in the last year I started using SQLite with my Clojure scripts instead of using a remote database, and I'm storing everything in git. Works like a charm for single-user tasks.

Do you store the binary .sqlite in Git or source .sql and build the .sqlite?

Wouldn't tracking the binary with Git make a new copy on every commit?

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#42

We use SQLite in an app with about 1,000 active users. It took us: - 0h to manage backups ("cp"), - 0h to manage seeds and tests fixtures ("cp"), - 0h to configure and secure (void), - 0h to write the deployment scripts (void), - 0h monitoring/watchdog jobs (void), - 1h to rsync for failover ("rsync") My last projects always spent at least a good 100h to do all of this the right way. Then, if it is not good enough, w…

Do you have a write-heavy workload? How do you handle contention? Do you have multiple servers? How do you handle real-time filesystem sync? If you only have one server, how do you handle its inevitable failure? Do you loose any data collected between last backup and failure? (I'm not saying SQLite isn't good, because it's f-ing amazing. I'm just not sold on it as a multi-process, multi-user database.) (If you have a…

> Do you have a write-heavy workload? How do you handle contention?

I'd also be interested in that. Last time I wanted to use Sqlite opening twice the same file for writing either would not succeed or could time out.

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#43
post #9

The mistale here is thinking that a "fancier DBMS" MUST be off-process. I totally wish for a fancier DBMS that can be embebed (firebird fit here!) and work on mobile (but not here yet). And not only "fancier" in the limited sense that most believe. I truly mean A LOT FANCIER.

MySQL Embedded[1] is a thing; used by some KDE apps. IIRC, it insists on using multiple files rather than a single file like SQLite does, but otherwise is a pretty much a turn-key component. No such luck with PostgreSQL so far.

[1] https://www.oracle.com/mysql/embedded.html

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#44
post #35

This is just a thought: SQLite is a really good file format. Why aren't we replacing CSV with it, especially for big data applications? CSV can be difficult and ambiguous to parse correctly (because there's no real standard) and isn't extremely performant. The only thing it has going for it is its universality. SQLite is lightweight, structured, supports indexing for performance and is extremely easy to use.

I used it. SQLite can even import directly from CSV (as long as you're only have ASCII characters). Joining several CSVs and the first data cleaning steps took a second instead of 30 minutes with pandas.

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#45
post #35

This is just a thought: SQLite is a really good file format. Why aren't we replacing CSV with it, especially for big data applications? CSV can be difficult and ambiguous to parse correctly (because there's no real standard) and isn't extremely performant. The only thing it has going for it is its universality. SQLite is lightweight, structured, supports indexing for performance and is extremely easy to use.

Don't underestimate the ability to see right away CSV contents using Excel/Numbers/Google Spreadsheets.

Non-coders technical users

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#46
post #35

This is just a thought: SQLite is a really good file format. Why aren't we replacing CSV with it, especially for big data applications? CSV can be difficult and ambiguous to parse correctly (because there's no real standard) and isn't extremely performant. The only thing it has going for it is its universality. SQLite is lightweight, structured, supports indexing for performance and is extremely easy to use.

> Why aren't we replacing CSV with it, especially in big data applications?

Simple, I can edit this with only a text editor if need be.

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#47
post #35

This is just a thought: SQLite is a really good file format. Why aren't we replacing CSV with it, especially for big data applications? CSV can be difficult and ambiguous to parse correctly (because there's no real standard) and isn't extremely performant. The only thing it has going for it is its universality. SQLite is lightweight, structured, supports indexing for performance and is extremely easy to use.

CSV's biggest competitor is XML.

But both XML and SQLite have the same issue: They give you just enough rope to hang yourself with. While SQLite is a fantastic micro-database engine and a file format, it isn't a very good universal B2B format because there are too many features you'd have to support to interoperate.

I'd argue CSV's biggest strength is that it is easy to parse correctly, because the format is so simple and the standard is largely the superset. The biggest problem for CSV is that the most popular desktop application for view CSV (Microsoft Excel) sucks at it, and causes data corruption on save (and has for at least twenty years).

If people wanted a relational database as a file, I can think of nothing better than SQLite, but in B2B you want automated tooling that can parse the format without human involvement. If you need some structure there are some simpler XML-based formats which accommodate that, but still offer far fewer features you'd have to support than SQLite does.

Ajax might become popular in this space, but I'm yet to see it.

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#48
post #35

This is just a thought: SQLite is a really good file format. Why aren't we replacing CSV with it, especially for big data applications? CSV can be difficult and ambiguous to parse correctly (because there's no real standard) and isn't extremely performant. The only thing it has going for it is its universality. SQLite is lightweight, structured, supports indexing for performance and is extremely easy to use.

CSV's biggest competitor is XML. But both XML and SQLite have the same issue: They give you just enough rope to hang yourself with. While SQLite is a fantastic micro-database engine and a file format, it isn't a very good universal B2B format because there are too many features you'd have to support to interoperate. I'd argue CSV's biggest strength is that it is easy to parse correctly, because the format is so simpl…

I'd actually argue that CSV's biggest competitor specifically is xlsx. Which is kind of XML...

Re: We’re happy with SQLite and not urgently interested in a fancier DBMS (2016)

#49

We use SQLite in an app with about 1,000 active users. It took us: - 0h to manage backups ("cp"), - 0h to manage seeds and tests fixtures ("cp"), - 0h to configure and secure (void), - 0h to write the deployment scripts (void), - 0h monitoring/watchdog jobs (void), - 1h to rsync for failover ("rsync") My last projects always spent at least a good 100h to do all of this the right way. Then, if it is not good enough, w…

> 0h to manage backups ("cp")

Are you aware that's unsafe? To make a safe backup use sqlite3's ".dump" command (or filesystem snapshotting, but I've had bad experiences with that, at least on btrfs).

Post reply on HN