tmcw / simpleopendata

simple guidelines for publishing open data in useful formats
https://simpleopendata.com/
89 stars 17 forks source link

Sugggestion - Publish Open (Structured) Data As Single-File SQLite Files - Gets You Tables n More #20

Closed geraldb closed 9 years ago

geraldb commented 9 years ago

Hello, First thanks for the great write-up and introduction to open data. May I suggest the best and simplest way to share open data (according to my opinion, of course ;-), that is, use single-file SQLite files. Why? The single-file SQLite file works on any machine (e.g. Linux, Mac, Windows, etc.). It includes an SQL schema for "free" and includes by definition "structured" data in tables. For examples, see the open beer database (e.g. beer.db) or open football database (e.g. football.db) or open world database (e.g. world.db). No need to reinvent schemas in JSON and relations and types etc. - use "plain old vanilla" SQL. Just a thought. It's a great and simple alternative for sharing open data online. Cheers. PS: Note: The SQLite code is public domain e.g. no "vendor" lock-in etc..

tmcw commented 9 years ago

I'm not totally convinced by this over CSV, seems like a leap in complexity to use a binary packed file format for tabular data.

geraldb commented 9 years ago

If all you have is a single table than, of course CSV is great (best). If you have two tables with relations (you might argue). If you have more than two tables and more than two relations than SQLite makes it way easier - it's not really a binary package (see it like a zipped-up single-file archive). Every table can easily get "exported" as plain text (CSV). The download is easier (just a single file - gets you many tables and the schema for "free"). Again the big plus is getting all relations right (and guranteed). For example, lets take the world.db - want to get all cities from Austria or from the state of Tyrol or from the county of Krems - it's easy - that's how SQL works. Anyways, thanks for your consideration. Keep it up the great work. Cheers.