PostgreSQL error code
PostgreSQL error 3D000
3D000 is the SQLSTATE PostgreSQL reports for invalid catalog name, in class 3D, Invalid Catalog Name.
| SQLSTATE | 3D000 |
|---|---|
| Condition name | invalid_catalog_name |
| Class | 3D — Invalid Catalog Name |
Reproduce it, then fix it
There is no database called shop on this server. current_database() names the one you’re connected to; a connection string pointing at the wrong database raises the same error when it connects. Run the broken query to see the error, then switch to the fixed one. Edit either freely; every run is rolled back.
SELECT pg_size_pretty(pg_database_size('shop'));SELECT current_database(), pg_size_pretty(pg_database_size(current_database()));