Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Data Bases > Pgsql Novice > Re: how to get ...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 2 of 3 Topic 3161 of 3215
Post > Topic >>

Re: how to get dependancies of a table?

by tgl@[EMAIL PROTECTED] (Tom Lane) Jul 7, 2008 at 10:07 AM

nobs@[EMAIL PROTECTED]
 (Emil Obermayr) writes:
> Instead I would prefer to see the dependancies. I have no idea where to
> look.

Fix whatever client you're using to not throw away NOTICE messages ...

regression=# create table foo (f1 int primary key);
NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "foo_pkey"
for table "foo"
CREATE TABLE
regression=# create table bar (d1 int references foo);
CREATE TABLE
regression=# create table baz (d1 int references foo);
CREATE TABLE
regression=# drop table foo;
NOTICE:  constraint baz_d1_fkey on table baz depends on table foo
NOTICE:  constraint bar_d1_fkey on table bar depends on table foo
ERROR:  cannot drop table foo because other objects depend on it
HINT:  Use DROP ... CASCADE to drop the dependent objects too.

			regards, tom lane

-- 
Sent via pgsql-novice mailing list (pgsql-novice@[EMAIL PROTECTED]
)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-novice
 




 3 Posts in Topic:
how to get dependancies of a table?
nobs@[EMAIL PROTECTED] (  2008-07-07 10:18:02 
Re: how to get dependancies of a table?
tgl@[EMAIL PROTECTED] (T  2008-07-07 10:07:59 
Re: how to get dependancies of a table?
nobs@[EMAIL PROTECTED] (  2008-07-09 09:12:50 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon Sep 8 3:05:17 CDT 2008.