modified databasehelper to prevent datbasehelper failure