Add some database fixes