fixing database error
modifying psotgres