How could this be user proof? You are essentially disabling the constraint that WILL enforce data integrity, then letting the user input whatever rubbish he wants to, and are then going to try and enable the constraint afterwards?
 
Not a good approach.. How can you ensure that the user hasn't put a duplicate value in (unique constraint) or something else that might break the constraint rule? The only way you are going to know is when you try and re-enable the constraint it will fail..
 
I struggle to see why you would want to do this - do you have any more info?
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of David Wagoner
Sent: 27 November 2001 21:30
To: Multiple recipients of list ORACLE-L
Subject: Script to Disable Constraint, Change Value, then Enable Constrain

Listers,

 

Does anyone have a script that will do the following:

 

  1. Accept user input for old data value
  2. Accept user input for new data value
  3. Disable table constraint
  4. Update record with new data value
  5. Enable constraint

 

A script like this would help ensure that constraints are not left “off” after updates, allowing “illegal” data into the tables.  Good user-proof script I would think.

 

 

TIA,

 

david

 

David B. Wagoner

Database Administrator

Arsenal Digital Solutions Worldwide Inc.

4815 Emperor Blvd., Suite 110

Durham, NC 27703

Tel. (919) 941-4645

Fax (919) 474-0735

Email mailto:[EMAIL PROTECTED]

Web http://www.arsenaldigital.com/

 

                                                                                                          ***  NOTICE  ***

This e-mail message is confidential, intended only for the named recipient(s) above and may contain information that is privileged, work product or exempt from disclosure under applicable law.  If you have received this message in error, or are not the named recipient(s), please immediately notify the sender at (919) 941-4645 and delete this e-mail message from your computer.  Thank you.

 

Reply via email to