DB/Misc: Fix db errors