• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Primary Key Generation broken when using permanentGlobalID and horizontal inheritance?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Primary Key Generation broken when using permanentGlobalID and horizontal inheritance?


  • Subject: Re: Primary Key Generation broken when using permanentGlobalID and horizontal inheritance?
  • From: Ramsey Gurley <email@hidden>
  • Date: Tue, 14 Dec 2010 14:44:42 -0500


On Dec 14, 2010, at 1:58 PM, René Bock wrote:

Hi all,

After migrating our CMS from WO 5.3 to 5.4 we noticed some strange effects on the PrimaryKey generation via EO_PK_TABLE

Our project makes extensive use of horizontal inheritance, using different models in different frameworks.

Normally,  there is (and should be) only on row per base entity in EO_PK_TABLE. But this rule was broken, when we try to call  anEo.permanentGlobalID()  for an unsaved eo.
It has the effect, that now in EO_PK_TABLE  there is an entry for anEo.entityName(), but the pk value of the base entity was not incremented (which leads to not so amusing effects)

As, of cause, I can't reproduce this behavior with a simple test application, I would like to here if anybody else has experienced this phenomena or hears ringing a bell?


I know OpenBase fails with HI for this same reason.  In the openbase plugin, the newPrimaryKeys() is incorrectly implemented and uses entity.externalName() to find the table name for key generation. It should use entity.primaryKeyRootName() instead. As a result, the leaf tables provide the primary key producing collisions.  



Luckily I can avoid calling permanentGlobalID on unsaved EOs, but not knowing why pk-generation may be broken, doesn't let me sleep to well...

I'm using WO.5.4.2, current Wonder _5_4_branche  and using either MySQL or Microsoft SqlServer...

I agree with Pascal. You should definitely update to WO 5.4.3.

Ramsey



regards,

René Bock
Software Engineering

--
Salient GmbH  -  the interactive advantage
http://www.salient.de http://www.openforms.de


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Primary Key Generation broken when using permanentGlobalID and horizontal inheritance? (From: René Bock <email@hidden>)

  • Prev by Date: Re: Quick ERXEnterpriseObject newly inserted Question --
  • Next by Date: Re: Primary Key Generation broken when using permanentGlobalID and horizontal inheritance?
  • Previous by thread: Re: Primary Key Generation broken when using permanentGlobalID and horizontal inheritance?
  • Next by thread: Component editor displays error when I use my helper function
  • Index(es):
    • Date
    • Thread