pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedhow can i drop a <unnamed> constraint
4+ messages / 2 participants
[nested] [flat]
* how can i drop a <unnamed> constraint
@ 2003-02-25 14:55 rute solipa <rutes@eselx.ipl.pt>
0 siblings, 0 replies; 4+ messages in thread
From: rute solipa @ 2003-02-25 14:55 UTC (permalink / raw)
To: pgsql-sql
hello,
i've got some tables where constraints don't have an explicit name, how can
i drop them.
best regards,
rute
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: how can i drop a <unnamed> constraint
@ 2003-02-25 15:05 Christoph Haller <ch@rodos.fzk.de>
0 siblings, 0 replies; 4+ messages in thread
From: Christoph Haller @ 2003-02-25 15:05 UTC (permalink / raw)
To: pgsql-sql; +Cc: rutes@eselx.ipl.pt
>
> i've got some tables where constraints don't have an explicit name,
how can
> i drop them.
>
Refer to the system catalogs section within the documentation.
pg_relcheck keeps track of constraints.
Regards, Christoph
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: how can i drop a <unnamed> constraint
@ 2003-02-25 15:23 Christoph Haller <ch@rodos.fzk.de>
0 siblings, 0 replies; 4+ messages in thread
From: Christoph Haller @ 2003-02-25 15:23 UTC (permalink / raw)
To: pgsql-sql; +Cc: rutes@eselx.ipl.pt
>
> >
> > i've got some tables where constraints don't have an explicit name,
> how can
> > i drop them.
> >
>
> Refer to the system catalogs section within the documentation.
> pg_relcheck keeps track of constraints.
>
>
More precisely
select relname , rcname from pg_class join pg_relcheck on (
pg_relcheck.rcrelid = pg_class.oid ) ;
Regards, Christoph
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: how can i drop a <unnamed> constraint
@ 2003-02-27 10:13 Christoph Haller <ch@rodos.fzk.de>
0 siblings, 0 replies; 4+ messages in thread
From: Christoph Haller @ 2003-02-27 10:13 UTC (permalink / raw)
To: pgsql-sql; +Cc: rutes@eselx.ipl.pt
>
> but with this query i only get the name from constraints type check ,
i
> need to get the names of all constraints types.
Not sure what exactly do you mean by this.
Have you done a SELECT * FROM pg_relcheck ;
to see what's all in there? Maybe an example would help.
>
> by the way, how can i disable constraints.
Within ALTER TABLE you can DROP constraints, I don't know if
there is a feature to temporarily disable constraints.
>
You should post to the list too. I'm not the expert on constraints.
Regards, Christoph
>
> At 04:23 PM 2/25/2003 +0100, you wrote:
> > >
> > > >
> > > > i've got some tables where constraints don't have an explicit
name,
> > > how can
> > > > i drop them.
> > > >
> > >
> > > Refer to the system catalogs section within the documentation.
> > > pg_relcheck keeps track of constraints.
> > >
> > >
> >More precisely
> >
> >select relname , rcname from pg_class join pg_relcheck on (
> >pg_relcheck.rcrelid = pg_class.oid ) ;
> >
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2003-02-27 10:13 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-02-25 14:55 how can i drop a <unnamed> constraint rute solipa <rutes@eselx.ipl.pt>
2003-02-25 15:05 Re: how can i drop a <unnamed> constraint Christoph Haller <ch@rodos.fzk.de>
2003-02-25 15:23 Re: how can i drop a <unnamed> constraint Christoph Haller <ch@rodos.fzk.de>
2003-02-27 10:13 Re: how can i drop a <unnamed> constraint Christoph Haller <ch@rodos.fzk.de>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox