Store events, compute state.

6 thoughts
last posted Feb. 4, 2013, 7:42 p.m.
0

In designing the schema for Gittip, I serendipitously chose to make the "tips" table INSERT-only instead of UPDATE. Any time you change a tip you insert the new tip but you still have the old one in there as well. In the application then you generally query for the latest tip, but since all the historic info is there you can do more as well.

5 later thoughts