Refreshing the schema causes the schema to disappear from the pgadmin3 tree. This is the query I see executed when doing the refresh:
SELECT CASE WHEN nspname LIKE 'pg\_temp\_%%' THEN 1
WHEN nsp.oid<17140 OR nspname like 'pg\_%' THEN 0
ELSE 2 END as nsptyp,
nsp.nspname, nsp.oid, pg_get_userbyid(nspowner) AS namespaceowner, nspacl, description, has_schema_privilege(nsp.oid, 'CREATE')
FROM pg_namespace nsp
LEFT OUTER JOIN pg_description des ON des.objoid=nsp.oid
WHERE nsp.oid=2147483647::oid
ORDER BY 1, nspname
I examined pg_namespace and the oid of the schema actually is 2518196330. No wonder pgadmin3 thinks it's empty.
Refreshing the "schema's" tree executes this statement:
SELECT CASE WHEN nspname LIKE 'pg\_temp\_%%' THEN 1
WHEN nsp.oid<17140 OR nspname like 'pg\_%' THEN 0
ELSE 2 END AS nsptyp,
nsp.nspname,
nsp.oid,
pg_get_userbyid(nspowner) AS namespaceowner,
nspacl,
description,
has_schema_privilege(nsp.oid, 'CREATE')
FROM pg_namespace nsp
LEFT OUTER JOIN pg_description des ON des.objoid=nsp.oid
WHERE (nsp.nspname NOT LIKE 'pg\_%' AND nsp.nspname NOT LIKE 'information_schema')
ORDER BY 1, nspname
The result of this query does list the schema with the correct OID (2518196330).
The question is: why does pgadmin3 think the oid for the schema is 2147483647 ?
I have this problem with a bunch of schema's, which makes pgadmin3 quite useless for me at the moment.
Please Cc me in the discussion, as I am not on this list.
Sincerely,
-- Richard van den Berg, CISSP
Trust Factory B.V. | http://www.trust-factory.com/ Bazarstraat 44a | Phone: +31 70 3620684 NL-2518AK The Hague | Fax : +31 70 3603009 The Netherlands |
---------------------------(end of broadcast)--------------------------- TIP 5: Have you checked our extensive FAQ?
http://www.postgresql.org/docs/faqs/FAQ.html