Search Postgresql Archives

DELETE FROM pg_class

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello, I see that I can modify system tables even though I have
not set allow_system_table_mods...  Is this a feature or a bug?

Self contained code

postgres=# SELECT version();
                                                    version
---------------------------------------------------------------------------------------------------------------
 PostgreSQL 8.2.4 on i486-pc-linux-gnu, compiled by GCC cc (GCC) 4.1.3
20070718 (prerelease) (Debian 4.1.2-14)
(1 row)

postgres=# SHOW allow_system_table_mods;
 allow_system_table_mods
-------------------------
 off
(1 row)

postgres=# CREATE DATABASE foo;
CREATE DATABASE
postgres=# \c foo
You are now connected to database "foo".
foo=# DELETE FROM pg_class;
DELETE 204
foo=# SELECT count(*) FROM pg_class;
ERROR:  could not find pg_class tuple for index 2662
foo=# \c postgres
You are now connected to database "postgres".
postgres=# \c foo
server closed the connection unexpectedly
        This probably means the server terminated abnormally
        before or while processing the request.
Previous connection kept
postgres=#


   Regards,
     Dawid

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux