Running the postgres part properly now