fix form and db