This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 124133

Summary: master table created without columns in primary key
Product: guibuilder Reporter: Patrick Keegan <pkeegan>
Component: BindingAssignee: issues@guibuilder <issues>
Status: RESOLVED DUPLICATE    
Severity: blocker    
Priority: P3    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:
Attachments: sql script

Description Patrick Keegan 2007-12-17 15:30:07 UTC
Using the New Java Desktop Application wizard, I create an app based on a DB created with the SQL script below. However,
the resulting master table does not contain the FIRST_NAME OR LAST_NAME fields, even though I want them both included. 
Neither of those fields are added as columns in the entity class either.  This seems to be related to the fact that I
made a primary key based on those two columns.

 CREATE TABLE CONTACTS18
    (
    FIRST_NAME VARCHAR(50),
    LAST_NAME VARCHAR(50),
    TITLE VARCHAR(50),
    NICKNAME VARCHAR(50),
    CONSTRAINT CONTACTS18_PK PRIMARY KEY (FIRST_NAME, LAST_NAME)
    );
  
   
INSERT INTO CONTACTS18 (FIRST_NAME, LAST_NAME, TITLE, NICKNAME)
       VALUES  	('Jake', 'Roberts', 'Mr.', '"The Snake"'), 
               	('Andre', 'Giant', 'Mr.', '"The Giant"');
Comment 1 Patrick Keegan 2007-12-17 16:07:53 UTC
Created attachment 54330 [details]
sql script
Comment 2 Jan Stola 2007-12-18 08:37:35 UTC
This is a known issue. Tables with a compound primary key should be handled better.

*** This issue has been marked as a duplicate of 105084 ***