updating new DB code