Fixed PostgreSQL data persistence