mirror of
https://github.com/postgres/postgres.git
synced 2025-06-13 07:41:39 +03:00
Additional fixes for large object access control.
Use pg_largeobject_metadata.oid instead of pg_largeobject.loid to enumerate existing large objects in pg_dump, pg_restore, and contrib modules.
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
/* $PostgreSQL: pgsql/contrib/lo/lo_test.sql,v 1.5 2007/11/13 04:24:28 momjian Exp $ */
|
||||
/* $PostgreSQL: pgsql/contrib/lo/lo_test.sql,v 1.6 2009/12/14 00:39:10 itagaki Exp $ */
|
||||
|
||||
-- Adjust this setting to control where the objects get created.
|
||||
SET search_path = public;
|
||||
@ -12,7 +12,7 @@ SET search_path = public;
|
||||
--
|
||||
|
||||
-- Check what is in pg_largeobject
|
||||
SELECT count(DISTINCT loid) FROM pg_largeobject;
|
||||
SELECT count(oid) FROM pg_largeobject_metadata;
|
||||
|
||||
-- ignore any errors here - simply drop the table if it already exists
|
||||
DROP TABLE a;
|
||||
@ -74,6 +74,6 @@ DELETE FROM a;
|
||||
DROP TABLE a;
|
||||
|
||||
-- Check what is in pg_largeobject ... if different from original, trouble
|
||||
SELECT count(DISTINCT loid) FROM pg_largeobject;
|
||||
SELECT count(oid) FROM pg_largeobject_metadata;
|
||||
|
||||
-- end of tests
|
||||
|
Reference in New Issue
Block a user