Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> Re: Declaring Unenforced Constraints

Re: Declaring Unenforced Constraints

From: Tony Andrews <andrewst_at_onetel.com>
Date: 17 Nov 2004 06:23:07 -0800
Message-ID: <1100701387.446990.147270@c13g2000cwb.googlegroups.com>


Kenneth Downs wrote:
> Bringing the db offline does not seem very nice, must be a better way
than
> that.

It depends on what you are doing, really. If this is a regular, frequent batch process to import new data into the database that must run while users are on-line, then it must be done in such a way that the users never see the "half-baked" data. This means that the dataload must use properly constructed transactions - i.e. NOT inserting all the "child" records without constraint, committing (so that they are visible to users), and THEN inserting all the "parent" records. With deferred constraints, you can load all the data (in any order) and then commit; however, that may be impractical for large data volumes. So then you may consider loading the data into temporary "staging" tables, and then having a subsequent process move the data into the real tables, again with constraints always in place. Received on Wed Nov 17 2004 - 08:23:07 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US