Fix db problem