fix database creation script