pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
v7.2 triggers and foreign keys
2+ messages / 2 participants
[nested] [flat]

* v7.2 triggers and foreign keys
@ 2004-05-20 18:32 Paul Gimpelj <pgimpelj@sympatico.ca>
  2004-05-21 08:11 ` Re: v7.2 triggers and foreign keys Richard Huxton <dev@archonet.com>
  0 siblings, 1 reply; 2+ messages in thread

From: Paul Gimpelj @ 2004-05-20 18:32 UTC (permalink / raw)
  To: pgsql-sql

Hi,

I have two tables a and b.; b references a.
I used pgaccess to create tables.
and psql to create the triggers and foreign keys. a has sequential id, and primary key same column.

As constraints they were implicit, and cascade was off.

On delete of the of a b row, postgres also deleted the a table row.

I then created a2 and b2 with action queries. and the delete acted as expected.

Where am i going wrong with this?
Do I need to install 7.4?

Also, created tables a3 and b3, with sequential ids using pgaccess same as a and b, and the seq id's don't increment with these tables.

Thanks.
paul

^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: v7.2 triggers and foreign keys
  2004-05-20 18:32 v7.2 triggers and foreign keys Paul Gimpelj <pgimpelj@sympatico.ca>
@ 2004-05-21 08:11 ` Richard Huxton <dev@archonet.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Richard Huxton @ 2004-05-21 08:11 UTC (permalink / raw)
  To: Paul Gimpelj <pgimpelj@sympatico.ca>; +Cc: pgsql-sql

Paul Gimpelj wrote:
> Hi,
> 
> I have two tables a and b.; b references a.
> I used pgaccess to create tables.
> and psql to create the triggers and foreign keys. a has sequential id, and primary key same column.
> 
> As constraints they were implicit, and cascade was off.
> 
> On delete of the of a b row, postgres also deleted the a table row.

You'll need to show the table definitions (with foreign keys etc) and 
also trigger definitions (use "\d table_a" in psql or "pg_dump 
--schema-only -t tablename")


-- 
   Richard Huxton
   Archonet Ltd



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2004-05-21 08:11 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2004-05-20 18:32 v7.2 triggers and foreign keys Paul Gimpelj <pgimpelj@sympatico.ca>
2004-05-21 08:11 ` Richard Huxton <dev@archonet.com>

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