update to psql statements