fixed an issue with creating db views in a new database