Bugzilla – Attachment 50735 Details for
Bug 16354
Fix FK constraints for edifact_messages table
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] Bug 16354 - TestBuilder.t fails due to key constraints
SIGNED-OFF-Bug-16354---TestBuildert-fails-due-to-k.patch (text/plain), 2.55 KB, created by
Bernardo Gonzalez Kriegel
on 2016-04-26 17:10:09 UTC
(
hide
)
Description:
[SIGNED-OFF] Bug 16354 - TestBuilder.t fails due to key constraints
Filename:
MIME Type:
Creator:
Bernardo Gonzalez Kriegel
Created:
2016-04-26 17:10:09 UTC
Size:
2.55 KB
patch
obsolete
>From be9966aeeb06287a3dff30a7829cd06639086ced Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Tue, 26 Apr 2016 15:45:38 +0000 >Subject: [PATCH] [SIGNED-OFF] Bug 16354 - TestBuilder.t fails due to key > constraints > >Test Plan: >1) prove t/db_dependent/TestBuilder.t >2) Note failure >3) Apply this patch >4) prove t/db_dependent/TestBuilder.t >5) Tests should now pass! > >Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> >Failure noted and corrected. >No errors >--- > installer/data/mysql/atomicupdate/bug_16354.sql | 9 +++++++++ > installer/data/mysql/kohastructure.sql | 6 +++--- > 2 files changed, 12 insertions(+), 3 deletions(-) > create mode 100644 installer/data/mysql/atomicupdate/bug_16354.sql > >diff --git a/installer/data/mysql/atomicupdate/bug_16354.sql b/installer/data/mysql/atomicupdate/bug_16354.sql >new file mode 100644 >index 0000000..768bd1d >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_16354.sql >@@ -0,0 +1,9 @@ >+ALTER TABLE edifact_messages >+ DROP FOREIGN KEY emfk_vendor, >+ DROP FOREIGN KEY emfk_edi_acct, >+ DROP FOREIGN KEY emfk_basketno; >+ >+ALTER TABLE edifact_messages >+ ADD CONSTRAINT emfk_vendor FOREIGN KEY ( vendor_id ) REFERENCES aqbooksellers ( id ) ON DELETE CASCADE ON UPDATE CASCADE, >+ ADD CONSTRAINT emfk_edi_acct FOREIGN KEY ( edi_acct ) REFERENCES vendor_edi_accounts ( id ) ON DELETE CASCADE ON UPDATE CASCADE, >+ ADD CONSTRAINT emfk_basketno FOREIGN KEY ( basketno ) REFERENCES aqbasket ( basketno ) ON DELETE CASCADE ON UPDATE CASCADE; >diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql >index 242755d..0111c09 100644 >--- a/installer/data/mysql/kohastructure.sql >+++ b/installer/data/mysql/kohastructure.sql >@@ -3223,9 +3223,9 @@ CREATE TABLE IF NOT EXISTS edifact_messages ( > KEY vendorid ( vendor_id), > KEY ediacct (edi_acct), > KEY basketno ( basketno), >- CONSTRAINT emfk_vendor FOREIGN KEY ( vendor_id ) REFERENCES aqbooksellers ( id ), >- CONSTRAINT emfk_edi_acct FOREIGN KEY ( edi_acct ) REFERENCES vendor_edi_accounts ( id ), >- CONSTRAINT emfk_basketno FOREIGN KEY ( basketno ) REFERENCES aqbasket ( basketno ) >+ CONSTRAINT emfk_vendor FOREIGN KEY ( vendor_id ) REFERENCES aqbooksellers ( id ) ON DELETE CASCADE ON UPDATE CASCADE, >+ CONSTRAINT emfk_edi_acct FOREIGN KEY ( edi_acct ) REFERENCES vendor_edi_accounts ( id ) ON DELETE CASCADE ON UPDATE CASCADE, >+ CONSTRAINT emfk_basketno FOREIGN KEY ( basketno ) REFERENCES aqbasket ( basketno ) ON DELETE CASCADE ON UPDATE CASCADE > ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; > > -- >-- >1.9.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 16354
:
50723
|
50735
|
50763