# E141-10: Names in a foreign key can be specified in any order

statement ok
CREATE TABLE TABLE_E141_10_01_011 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_012 ( C INT NOT NULL, D INT NOT NULL, CONSTRAINT CONST_E141_10_01_01 FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_011 ( B, A ) )

statement ok
CREATE TABLE TABLE_E141_10_01_021 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_022 ( C INT NOT NULL, D INT NOT NULL, CONSTRAINT CONST_E141_10_01_02 FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_021 ( B, A ) ON DELETE NO ACTION )

statement ok
CREATE TABLE TABLE_E141_10_01_031 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_032 ( C INT NOT NULL, D INT NOT NULL, CONSTRAINT CONST_E141_10_01_03 FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_031 ( B, A ) ON UPDATE NO ACTION )

statement ok
CREATE TABLE TABLE_E141_10_01_041 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_042 ( C INT NOT NULL, D INT NOT NULL, CONSTRAINT CONST_E141_10_01_04 FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_041 ( B, A ) ON UPDATE NO ACTION ON DELETE NO ACTION )

statement ok
CREATE TABLE TABLE_E141_10_01_051 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_052 ( C INT NOT NULL, D INT NOT NULL, FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_051 ( B, A ) )

statement ok
CREATE TABLE TABLE_E141_10_01_061 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_062 ( C INT NOT NULL, D INT NOT NULL, FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_061 ( B, A ) ON DELETE NO ACTION )

statement ok
CREATE TABLE TABLE_E141_10_01_071 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_072 ( C INT NOT NULL, D INT NOT NULL, FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_071 ( B, A ) ON UPDATE NO ACTION )

statement ok
CREATE TABLE TABLE_E141_10_01_081 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_01_082 ( C INT NOT NULL, D INT NOT NULL, FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_01_081 ( B, A ) ON UPDATE NO ACTION ON DELETE NO ACTION )

statement ok
CREATE TABLE TABLE_E141_10_02_011 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_02_012 ( C INT NOT NULL, D INT NOT NULL, CONSTRAINT CONST_E141_10_02_01 FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_02_011 ( B, A ) ON DELETE NO ACTION ON UPDATE NO ACTION )

statement ok
CREATE TABLE TABLE_E141_10_02_021 ( ID INT PRIMARY KEY, A INT NOT NULL, B INT NOT NULL, UNIQUE ( A, B ) );

# CREATE TABLE TABLE_E141_10_02_022 ( C INT NOT NULL, D INT NOT NULL, FOREIGN KEY ( C, D ) REFERENCES TABLE_E141_10_02_021 ( B, A ) ON DELETE NO ACTION ON UPDATE NO ACTION )
