Bug 1267538 - Wrong Foreign Key reference when exporting Dynamic VDB
Wrong Foreign Key reference when exporting Dynamic VDB
Status: CLOSED CURRENTRELEASE
Product: JBoss Data Virtualization 6
Classification: JBoss
Component: Tooling (Show other bugs)
unspecified
Unspecified Unspecified
unspecified Severity high
: ---
: ---
Assigned To: Barry LaFond
Andrej Smigala
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-09-30 07:03 EDT by Andrej Smigala
Modified: 2015-11-17 13:06 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-11-17 13:06:57 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
project (25.88 KB, application/zip)
2015-09-30 07:03 EDT, Andrej Smigala
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
JBoss Issue Tracker TEIIDDES-2672 Major Closed Wrong Foreign Key reference when exporting Dynamic VDB 2015-10-20 08:20 EDT

  None (edit)
Description Andrej Smigala 2015-09-30 07:03:58 EDT
Created attachment 1078592 [details]
project

When creating a dynamic VDB from an existing VDB, Foreign Key definitions use the wrong table in the REFERENCES clause. The reference table is the same as the one that contains this FK.
For example, in the table SUPPLIER_PARTS, the following constraint is generated:

CONSTRAINT FK_SPLIER_PRTS_SPLY FOREIGN KEY(SUPPLIER_ID) REFERENCES SUPPLIER_PARTS(SUPPLIER_ID)

which is obviously wrong. The correct constrant definition should be:

CONSTRAINT FK_SPLIER_PRTS_SPLY FOREIGN KEY(SUPPLIER_ID) REFERENCES SUPPLIER(SUPPLIER_ID)


Steps to Reproduce:
# import the attached project
# right click the vdb, select Modeling -> Generate Dynamic VDB
# click Next, click Generate
# find the DDL for table SUPPLIER_PARTS, notice the FOREIGN KEY definitions
Comment 2 JBoss JIRA Server 2015-09-30 11:20:53 EDT
Barry LaFond <blafond@jboss.org> updated the status of jira TEIIDDES-2672 to Resolved
Comment 3 JBoss JIRA Server 2015-10-20 03:14:45 EDT
Matus Makovy <mmakovy@redhat.com> updated the status of jira TEIIDDES-2672 to Closed

Note You need to log in before you can comment on or make changes to this bug.