constraint=constraints?
偶然發現在為欄位增加約束時使用constraint或者constraints都可以建立成功,檢視oracle語法發現是constraint,不知道是否是bug?
[@more@]SQL> create table t(id int primary key);
表已建立。
SQL> create table tt(id int);
表已建立。
SQL> alter table tt add constraint fk_tt foreign key (id) references t(id);
表已更改。
SQL> alter table tt drop constraint fk_tt;
表已更改。
SQL> alter table tt add constraints fk_tt foreign key (id) references t(id);
表已更改。
SQL>
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/19602/viewspace-1001522/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- all_constraints 表欄位Constraint_type值含義AI
- HV000030: No validator could be found for constraint ‘javax.validation.constraints.Pattern‘ validatiAIJava
- ConstraintAI
- SQL Server Primary Key ConstraintsSQLServerAI
- Drop table cascade constraintsAI
- imp INDEXES=N CONSTRAINTS=NIndexAI
- Define Constraints on Views (188)AIView
- 約束CONSTRAINTAI
- constraint約束AI
- Unused&ConstraintAI
- Certificates does not conform to algorithm constraintsORMGoAI
- DROP TABLE ** CASCADE CONSTRAINTS PURGEAI
- Deferred Constraint CheckAI
- Could not resolve com.android.support.constraint:constraint-layout:1.1.3AndroidAI
- Oracle constraints type 約束型別OracleAI型別
- Oracle基礎 11 約束 constraintsOracleAI
- Will attempt to recover by breaking constraintAI
- CONSTRAINT的用法舉例AI
- Constraint deferrable特性研究AI
- constraint deferrable immediate checkAI
- Deferring Constraint ChecksAI
- MySQL——約束(constraint)詳解MySqlAI
- 討論關於Constraint statesAI
- Use the following approach to create tables with constraints and indexes:APPAIIndex
- iOS 常用佈局方式之ConstraintiOSAI
- dba_objects 中不包含 constraintObjectAI
- 資料庫學習(1) - constraint資料庫AI
- 10、Oracle中的約 束constraintOracleAI
- odoo 開發入門教程系列-約束(Constraints)OdooAI
- IMP Takes More Time To Import The Constraints (Doc ID 166887.1)ImportAI
- 外來鍵約束drop table cascade constraintsAI
- Data Warehouse Guide文件筆記(三):RELY constraintsGUIIDE筆記AI
- 主子表drop table constraints cascade的測試AI
- transaction-level or statement-level consistency; check constraintsAI
- [20170421]impdp SKIP_CONSTRAINT_ERRORSAIError
- constraint enable,disable的問題解決AI
- constraint和index的一點關係!AIIndex
- Constraint State(disable/enable validate/noalidate)AI