Any example of a necessary nullable foreign key?

后端 未结 8 1798
感情败类
感情败类 2020-12-03 01:42
Customers
 customer_id

Orders
 order_id
 customer_id fk

If I have two tables and define a foreign key on customer_id in the Orders table, by allow

8条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-03 02:21

    To set a foreign key nullable or null use below sql script

    ALTER TABLE Return_COMMENTS MODIFY order_ID Number NULL;
    

提交回复
热议问题