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.
Hi guys i just made changes to my database, i tried to use the new entities update feature. the outcome was i got a lot of duplicates, because i renamed all my foreign key attributes to the entity name(class name), it assumed that those attributes where missing. these are the attributes already there(these i changed to meet my needs). @JoinColumn(name = "ServiceProviderID", referencedColumnName = "ServiceProviderID") @ManyToOne(optional = false, fetch = FetchType.EAGER) private Serviceprovider serviceProvider; @JoinColumn(name = "SimTypeID", referencedColumnName = "SimTypeID") @ManyToOne(optional = false, fetch = FetchType.EAGER) private Simtype simType; these are the newly generated ones, which are the same @JoinColumn(name = "ServiceProviderID", referencedColumnName = "ServiceProviderID") @ManyToOne(optional = false) private Serviceprovider serviceProviderID; @JoinColumn(name = "SimTypeID", referencedColumnName = "SimTypeID") @ManyToOne(optional = false) private Simtype simTypeID;
it's not necessary to rename something, the same is reproducible if generate discoundcode and customer from sample database and update it without modification, both entities will contain duplicates.
Integrated into 'main-golden', will be available in build *201006080001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/6c0ce8a602d2 User: Sergey B. Petrov <sj-nb@netbeans.org> Log: fix #185882 some work, no imprvement yet
Integrated into 'main-golden', will be available in build *201006100001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/06a801bf5a27 User: Sergey B. Petrov <sj-nb@netbeans.org> Log: fix #185882 a bit more
Integrated into 'main-golden', will be available in build *201006110001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/8c078799c83e User: Sergey B. Petrov <sj-nb@netbeans.org> Log: fix #185882 discountcode+customer case without renaming seems to be covered now
Integrated into 'main-golden', will be available in build *201006120001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/217dd89aeda3 User: Sergey B. Petrov <sj-nb@netbeans.org> Log: fix #185882 discountcode+customer case with renamed discountCode id and renamed relation works
Integrated into 'main-golden', will be available in build *201006250001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/e599d15f8b20 User: Sergey B. Petrov <sj-nb@netbeans.org> Log: fix #185882 collect existing JoinColumns
Integrated into 'main-golden', will be available in build *201006290001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/d48e5095a37b User: Sergey B. Petrov <sj-nb@netbeans.org> Log: fix #185882 - collect jointables, do not duplicate jointable and joincolumns (udate isn't implemented)
Created attachment 100493 [details] schema used for testing
http://hg.netbeans.org/web-main/rev/c6f653aa274a on attached schema there are no duplicates, ome minor cases may not be handled but need to be filed separately. Also need to implement more smart update instead not updating in some cases and plain update in other.
Integrated into 'main-golden', will be available in build *201006300001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/c6f653aa274a User: Sergey B. Petrov <sj-nb@netbeans.org> Log: fix #185882 - missed manytomany added, the issue can be considered as fixed now