logoalt Hacker News

There's no single best way to store information

41 pointsby 7777777philtoday at 4:17 PM16 commentsview on HN

Comments

ronsortoday at 7:44 PM

There are plenty of good enough ways:

* For lossless compression of generic data, gzip or zstd.

* For text, documentation, and information without fancy formatting, markdown, which is effectively a plain-text superset.

* For small datasets, blobs, objects, and what not, JSON.

* For larger datasets and durable storage, SQLite3.

Whenever there's text involved, use UTF-8. Whenever there's dates, use ISO8601 format (UTC timezone) or Unix timestamps.

Following these rules will keep you happy 80% of the time.

show 1 reply
dananstoday at 7:40 PM

Pedantic, but the article is talking about the way we structure/organize information, not store it. When I think of the word store, I think of the physical medium. The way we organize the information is only partially related

bob1029today at 7:16 PM

The best way to store information depends on how you intend to use (query) it.

The query itself represents information. If you can anticipate 100% of the ways in which you intend to query the information (no surprises), I'd argue there might be an ideal way to store it.

show 2 replies
__MatrixMan__today at 6:05 PM

There are, however, several objectively bad ways. In "Service Model" (a novel that I recommend) a certain collection of fools decides to sort bits by whether it's a 1 or a 0, ending up with a long list of 0's followed by a long list of 1's.

show 4 replies
andixtoday at 7:25 PM

It's always Markdown. Markdown is the best way to store information. ;)

show 1 reply
pbreittoday at 5:47 PM

Postgres is close.

show 2 replies
kittikittitoday at 7:08 PM

Or it's the opposite, where the slowest possible retrieval time is the intended effect, as is the basis of many cryptographic algorithms.