base: database table fixes

* Fixes inconsistencies in table definitions between master and pu-branch.

Signed-off-by: Lars Holm Nielsen <lars.holm.nielsen@cern.ch>