constraints
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 4 of 4

Thread: constraints

  1. #1
    Join Date
    Jun 2001
    Posts
    316
    Hi,
    is it possible to force a cascade delete if i ve not initialized during the creation of the intergrity cascade delete?

    thanx

  2. #2
    Join Date
    Jun 2001
    Posts
    56

    Write a detail, What do u want ?

  3. #3
    Join Date
    Jun 2001
    Posts
    316
    Its like

    I have 2 tables all related to each other in some way

    when i try to delete the contenst of 1 table it says" child in other " so cannot delete

    in the 2nd table if i try to insert..it says "record not found in 1st table cause 1 feild related to a column in first table

    Now i get a file every 15 days for thses updates and delete
    1 file for each table
    he file contains the delete and insert statements

    if i try to execute the 1st file it inserts properly but cannot delete as child xists

    if i try to execute 2nd first it deleted properly but cannot insert as primary not fiund..
    i hope u c what the problem is

    i can drop the constraint and recreate it
    but is there ay other way out?

    thanx


  4. #4
    Join Date
    May 2000
    Location
    Portsmouth, NH, USA
    Posts
    378

    Thumbs up


    alter table disable constraint name;

    when done with your alterations, ENABLE the constraint(s) again.

    normally spooling a disable script and an enable script is very helpful by selecting from dba_constraints where owner = schema you have your tables under.

    that make sense?

    - Magnus

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width