
Foundations of Databases (1995) - tosh
http://webdam.inria.fr/Alice/
======
craigkerstiens
I'd also highly recommend the redbook (readings in databases) which is by
several luminaries in the database world including Peter Bailis, Joe
Hellerstein, and Michael Stonebraker. They also updated it in recent years to
ensure it was up to date for the latest research on databases as well -
[http://www.redbook.io/](http://www.redbook.io/)

~~~
chess93
There is also a "Red Book" in mathematics. It is David Mumford's Algebraic
Geometry book.

Are there any other fields with a "Red Book"? I am mildly curious.

~~~
tamasnet
IBM has a division which produces technical books based on internal staff,
business partner and client contributions. They've been doing this for quite a
long time (I participated in one almost 20 years ago). Historically they had
red covers and so to this day they are called the Redbooks.
[http://www.redbooks.ibm.com](http://www.redbooks.ibm.com)

------
acacar
My Ph.D. advisor gave me his copy when I was just getting started with my
thesis, almost twenty years ago. I remember spending 6-7 very intense weeks
with it. It gave me most of the mathematical/logical background specific to
databases I needed to finish what was primarily a DB focused dissertation. I
kept coming back to it all through my studies and later.

If you ever need to design a logically sound query processor/optimizer and/or
data storage layer, this is a book you should study.

It still sits on my bookshelf, waiting for the student whose interest in
databases is deeper than dujourDB, so that I can pass it down to them.

~~~
ativzzz
What are you working on now? If in industry, do you actively use what you
learned in your PHD? Was it worth it?

~~~
acacar
Mostly bioinformatics these days. I’m in academia, and have been virtually all
my career, so I can’t really speak to whether a Ph.D. is worth it in industry.

------
billfruit
Of all the database theory books I have seen, I found the C.J Date book(An
Introduction to Database Systems) to be the most elegant one, though the
edition I used attempted to use tutorialD than SQL. What I liked is that it
brought out the beauty of relational algebra to the reader with great clarity.

~~~
mistrial9
.. with a caveat of his efforts to remove NULL

~~~
j88439h84
That's definitely part of the elegance from my perspective.

~~~
geertj
I used to think this also. However after diving really deep into OLAP for
business reporting over the last 6 months, I find NULL to be the single most
powerful idea in SQL. Here’s some use cases for NULL that I find super useful:

COUNT(case when <complex condition> then 1 end) as foo

Count occurrences of complex condition over a row set. Works because COUNT
ignores null.

NVL(1/NULLIF(foo, 0), 0)

Protect against division by zero. The expression 1/X is a simple example but
this generalizes well. In fact, I’ve come to think that NULL turns any SQL
value into a Monadic option type like those used functional languages and
Rust.

Note that I’m not saying the above cannot be done without NULL, just that NULL
is a really useful tool in my experience.

~~~
tonyg
It's exactly unlike a monadic option type. It's much more like null is in
Java, C# etc. Every type gets a NULL value here, where in ML/Haskell/etc use
of Option/Maybe/etc is explicit.

~~~
quelltext
I believe they were well aware.of that but specifically pointing out
similarity with Maybe in how NULL values just bubble up just like Nothing.

This is very different from Java, where a chain of operation on null values
typically very quickly leads to runtime exceptions.

------
mitchtbaum
Chapter 3, 'The Structure of the Relational Model', has a helpful background
on the origins of _table-oriented_ relational algebra. Unfortunately, it
misses the importance of graphs, which afaict, transcend the dependence on
tables' bias for normalized topologies of pathologically regular 2D metric
spaces, and it even reinforces their relevance by saying, "Intuitively, the
data is represented in tables...". Whereas,

> Graphs allow us to build complex, intuitive relationships between data
> points. Unlike many traditional methods of structuring data, which focus on
> the _format_ of relationships, graphs focus on the _topology_ of
> relationships in the dataset.

[https://blog.usejournal.com/data-modelling-with-graph-
theory...](https://blog.usejournal.com/data-modelling-with-graph-theory-
part-1-introduction-f52aaf11f974)

When it comes to making database concepts more intuitive, I find visually rich
representations very helpful, for example using geometric space-encoded
logical relationships to aid diagrammatic reasoning.

It goes along well with many other people's efforts to improve mathematical
represenations and interfaces through intuitive visualizations, ie:

[https://intuitive-math.club/](https://intuitive-math.club/)

[http://acko.net/](http://acko.net/)

[https://www.reddit.com/r/mathgifs/](https://www.reddit.com/r/mathgifs/)

[https://www.reddit.com/r/visualizedmath/](https://www.reddit.com/r/visualizedmath/)

...

------
mushishi
If you are curious how databases are implemented, here is a simplistic
implementation in clear abstractions
[https://github.com/komu/ahwen](https://github.com/komu/ahwen)

It's a good idea to familiarise with the code in bottom-up order of layers.

Readme says this: > The implementation takes heavy inspiration from Edward
Sciore's SimpleDB, augmented by implementations of various exercises in his
textbook Database Design and Implementation.

~~~
amelius
Nice. It would be interesting to have such an implementation for a distributed
database as well.

------
fnord123
Another great resource: [https://bigdata.uni-
saarland.de/datenbankenlernen/](https://bigdata.uni-
saarland.de/datenbankenlernen/)

------
bostonvaulter2
I see that this is now #3 on the homepage with 112 points but no comments yet.
Are people already very familiar with this work? Can some expound on its
merits?

~~~
mj_olnir
I'm curious too. As a CS grad student with relatively little database
knowledge, would this be a good text to start learning?

~~~
evil-olive
I haven't fully read it (yet), but based on a quick scan of a few chapters, it
looks like a dense but well-written introduction.

Some additional resources I'd recommend if you're interested:

Designing Data-Intensive Applications is a fantastic place to start if you're
interested in the intersection of databases & distributed systems:

[https://dataintensive.net/](https://dataintensive.net/)

The Architecture of Open-Source Applications book has a fewer chapters on
databases:

[https://aosabook.org/en/bdb.html](https://aosabook.org/en/bdb.html)

[https://aosabook.org/en/hdfs.html](https://aosabook.org/en/hdfs.html)

[https://aosabook.org/en/nosql.html](https://aosabook.org/en/nosql.html)

There's some fantastic documentation on Postgres and its internals:

[http://www.interdb.jp/pg/index.html](http://www.interdb.jp/pg/index.html)

[https://momjian.us/main/presentations/internals.html](https://momjian.us/main/presentations/internals.html)

[https://www.postgresql.org/docs/current/internals.html](https://www.postgresql.org/docs/current/internals.html)

~~~
mj_olnir
Thanks so much! I'll definitely take a look into these.

------
slyrus
I took Serge's class when he was on sabbatical (?) teaching at UC Berkeley
back in the days of steam-powered web browsers. Was a great course but it felt
like the theory wasn't _quite_ there yet to be the next big thing in
databases.

------
aikah
Looks like a great textbook. I'm really looking for a book on relational
database implementation itself, but I understand this is a topic so large that
a single book probably could never cover it all.

------
megakluntjes
My Tip: Grab an old cheap copy of "Database Systems: The Complete Book" (by
Hector Garcia-Molina, Jeffrey D. Ullman and Jennifer Widom).

Here is an updated edition:
[https://www.amazon.com/dp/129202447X/](https://www.amazon.com/dp/129202447X/)

------
tonetheman
Another interesting link on making your own DB:
[https://cstack.github.io/db_tutorial/](https://cstack.github.io/db_tutorial/)

------
commandlinefan
Damn, the PDF download is not working but it specifically says not to post the
PDF anywhere else...

~~~
sbuttgereit
Works fine for me.

~~~
commandlinefan
Looks like it was temporary. Whew!

