sql >> データベース >  >> RDS >> Oracle

右括弧がありません:削除時、更新カスケード時にNullを設定(SQL / Oracle)

    Oracleでは、更新時カスケードは使用できません。トムカイトは言う:

    There is not "on update cascade" automagically.
    
    There are ways to do it, 
    
    o deferrable constraints.  defer the foreign key check until commit, update the parent, 
    update the child and then commit.
    
    Personally -- I've never found a need or use for update cascade.  I'm opposed to it.  If 
    your design requires it -- change your design now if you can.  
    
    
    Primary keys are supposed to be imutable, never changing, constant.  It is an excessively 
    bad practice to have to update them ever.  If there is a 0.00001% chance you will have to 
    update a primary key -- then it is not a primary key, its a surrogate key and you need to 
    find the true primary key (even if you have to make it up via a sequence) 
    

    このリンクを確認してください




    1. codeigniterを使用して各カテゴリの降順で3つのレコードを取得する

    2. 2つのMySQLダンプの違いを確認するにはどうすればよいですか?

    3. PHP変換日付形式

    4. 明示カーソルのSQLステートメントを返す