updates to postgres sql