pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedREFRENTIAL INTEGRITY CHECKING
4+ messages / 3 participants
[nested] [flat]
* REFRENTIAL INTEGRITY CHECKING
@ 2001-07-16 17:11 Sudheer Palaparambil <p_sudheers@rediffmail.com>
2001-07-16 18:48 ` Re: REFRENTIAL INTEGRITY CHECKING Thalis A. Kalfigopoulos <thalis@cs.pitt.edu>
2001-07-16 18:51 ` Re: REFRENTIAL INTEGRITY CHECKING Stephan Szabo <acroyear_07030@yahoo.com>
0 siblings, 2 replies; 4+ messages in thread
From: Sudheer Palaparambil @ 2001-07-16 17:11 UTC (permalink / raw)
To: pgsql-admin
Hi,
How do we avoid referential integrity (FOREIGN KEY) checking till commit. My pgsql server
is checking it as soon as I am issueing an INSERT command. Pls help.
Thanks in advance.
Sudheer
____________________________________________________
http://www.monsterindia.com - The Best Jobs. For the Best Minds.
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: REFRENTIAL INTEGRITY CHECKING
2001-07-16 17:11 REFRENTIAL INTEGRITY CHECKING Sudheer Palaparambil <p_sudheers@rediffmail.com>
@ 2001-07-16 18:48 ` Thalis A. Kalfigopoulos <thalis@cs.pitt.edu>
2001-07-16 20:22 ` Re: REFRENTIAL INTEGRITY CHECKING Thalis A. Kalfigopoulos <thalis@cs.pitt.edu>
1 sibling, 1 reply; 4+ messages in thread
From: Thalis A. Kalfigopoulos @ 2001-07-16 18:48 UTC (permalink / raw)
To: Sudheer Palaparambil <p_sudheers@rediffmail.com>; +Cc: pgsql-admin
On 16 Jul 2001, Sudheer Palaparambil wrote:
> Hi,
>
> How do we avoid referential integrity (FOREIGN KEY) checking till commit. My pgsql server
> is checking it as soon as I am issueing an INSERT command. Pls help.
>
> Thanks in advance.
SET CONSTRAINTS TO DEFERRED
This will do the job only if your fk was not defined as INITIALLY IMMEDIATE NOT DEFERRABLE
cheers,
thalis
>
> Sudheer
>
> ____________________________________________________
> http://www.monsterindia.com - The Best Jobs. For the Best Minds.
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
>
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: REFRENTIAL INTEGRITY CHECKING
2001-07-16 17:11 REFRENTIAL INTEGRITY CHECKING Sudheer Palaparambil <p_sudheers@rediffmail.com>
2001-07-16 18:48 ` Re: REFRENTIAL INTEGRITY CHECKING Thalis A. Kalfigopoulos <thalis@cs.pitt.edu>
@ 2001-07-16 20:22 ` Thalis A. Kalfigopoulos <thalis@cs.pitt.edu>
0 siblings, 0 replies; 4+ messages in thread
From: Thalis A. Kalfigopoulos @ 2001-07-16 20:22 UTC (permalink / raw)
To: Sudheer Palaparambil <p_sudheers@rediffmail.com>; +Cc: pgsql-admin
On Mon, 16 Jul 2001, Thalis A. Kalfigopoulos wrote:
> On 16 Jul 2001, Sudheer Palaparambil wrote:
>
> > Hi,
> >
> > How do we avoid referential integrity (FOREIGN KEY) checking till commit. My pgsql server
> > is checking it as soon as I am issueing an INSERT command. Pls help.
> >
> > Thanks in advance.
>
> SET CONSTRAINTS TO DEFERRED
Sorry, it's actually:
SET CONSTRAINTS <constraint_name> TO DEFERRED
IF you don't want to give a specific constraint name, just give ALL.
cheers,
thalis
>
> This will do the job only if your fk was not defined as INITIALLY IMMEDIATE NOT DEFERRABLE
>
> cheers,
> thalis
>
> >
> > Sudheer
> >
> > ____________________________________________________
> > http://www.monsterindia.com - The Best Jobs. For the Best Minds.
> >
> >
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 2: you can get off all lists at once with the unregister command
> > (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
> >
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
>
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: REFRENTIAL INTEGRITY CHECKING
2001-07-16 17:11 REFRENTIAL INTEGRITY CHECKING Sudheer Palaparambil <p_sudheers@rediffmail.com>
@ 2001-07-16 18:51 ` Stephan Szabo <acroyear_07030@yahoo.com>
1 sibling, 0 replies; 4+ messages in thread
From: Stephan Szabo @ 2001-07-16 18:51 UTC (permalink / raw)
To: Sudheer Palaparambil <p_sudheers@rediffmail.com>; pgsql-admin
--- Sudheer Palaparambil <p_sudheers@rediffmail.com>
wrote:
> Hi,
>
> How do we avoid referential integrity (FOREIGN
> KEY) checking till commit. My pgsql server
> is checking it as soon as I am issueing an INSERT
> command. Pls help.
When you define the constraint, set it as INITIALLY
DEFERRED (or if you only sometimes want it to defer,
set it as DEFERRABLE and use SET CONSTRAINTS to change
the mode)
However, there are some problems with the deferred ri
right now if you modify the same key more than once in
a transaction -- I'm hoping to get a chance to fix
that for 7.2. For now, you have to be careful.
__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2001-07-16 20:22 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-07-16 17:11 REFRENTIAL INTEGRITY CHECKING Sudheer Palaparambil <p_sudheers@rediffmail.com>
2001-07-16 18:48 ` Thalis A. Kalfigopoulos <thalis@cs.pitt.edu>
2001-07-16 20:22 ` Thalis A. Kalfigopoulos <thalis@cs.pitt.edu>
2001-07-16 18:51 ` Stephan Szabo <acroyear_07030@yahoo.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