Moved PostgreSQL classes to top-level