DB design 1.0

to do: test rebuild script.