3 ms·
Any cool "create a database from scratch" books? Sounds like a fun read. Like The Grapics Programming Black Book, but for databases. Of course there's plenty o
by winrid 5y ago
Any cool "create a database from scratch" books? Sounds like a fun read. Like The Grapics Programming Black Book, but for databases.
Of course there's plenty of literature on individual components, but a holistic view would be fun to read.
I suppose you could read sqlite or postgres code... but that doesn't fit well on a Kindle. :)
- azhenley 5y agoDatabase Design for Mere Mortals
- deleted 5y ago[deleted]
- rubyn00bie 5y agoYes indeed, friend! This one is a classic: https://cstack.github.io/db_tutorial/ https://cstack.github.io/db_tutorial/ It's a sqlite clone from scratch.
- ddlutz 5y agoHave you gone through it? I've seen it around for years, however it unfortunately looks unfinished and unmaintained. I think I'd be unfulfilled going through all of it just to not have a finished tutorial.
- eatonphil 5y agoIt's not a book but I wrote a series on writing a postgres clone from scratch in Go. https://notes.eatonphil.com/tags/database.html https://notes.eatonphil.com/tags/database.html
- bob1029 5y agoYou could also start from first principles and essential abstractions. If you build a solid key-value store, it is possible to construct higher-order stores on top. Once you can quickly find a thing with some key, any degree of structure and complexity is possible from that point. Column-based, row-based, document-based, etc. All are possible to build on top of K-V. Might not be the most optimal solution, but it is a very accessible path in my experience. You can start defining types like Table, Column, Row, Document, etc. which all leverage this idea that you can trivially refer to another thing by some identifier. For instance, Table.FirstRowId and Table.LastRowId could be used to refer to the logical extents of a collection of rows that might be linked together both ways (e.g. Row.PreviousRowId, Row.NextRowId).
- winrid 5y agoThat's definitely a good approach. I'm fortunate enough that I can learn just by reading, so I like to just lay down and read coding/comp-sci stuff when I can. Like, If I wanted to, I bet I know I could create the server, connection manager, query parser, optimizer, WAL, storage... and maybe I will, but would just be fine to read about someone else doing it. I spend enough time coding as it is. :)
- SilverRed 5y agoThis would be basically doing all of the research and learning on databases from the last few decades from scratch. It probably won't give you a good understanding of how a modern DB works though.
- silentsea90 5y agoThe book referenced on the blog post seems interesting: Database Internals: A Deep Dive into How Distributed Data Systems Work https://www.amazon.com/_/dp/1492040347 https://www.amazon.com/_/dp/1492040347