Fix DB problems