same connection dictionary like "i think they're the same because the url is 
the same" or same like "i tested with .equals(..) at runtime and it returns 
true thereby proving they're the same" (technically they don't have to be 
exactly .equals, but if they are .equals, they are same-enough)

On Dec 14, 2009, at 10:22 PM, Ren, Kevin wrote:

> 
> HI,
> 
> I checked that, they are same connection dictionary, because this just moral 
> test example.
> 
> Not using WOnder,
> 
> Thanks
> 
> Kevin
> 
>> -----Original Message-----
>> From: Chuck Hill [mailto:ch...@global-village.net] 
>> Sent: Tuesday, 15 December 2009 4:18 p.m.
>> To: Ren, Kevin
>> Cc: webobjects-dev@lists.apple.com
>> Subject: Re: NullPointerException in many-many relationship 
>> cross two models
>> 
>> Both models need to have the exact (and I _do_ mean _exact_) 
>> same connection dictionary.  The dictionaries must be 
>> equals().  This is most easily accomplished by setting the 
>> programatically when the app loads.  Wonder, of course, does this.
>> 
>> 
>> Chuck
>> 
>> 
>> On Dec 14, 2009, at 3:30 PM, Ren, Kevin wrote:
>>> Hi,
>>> 
>>> There is m-m relationship between A and B entities which are in 
>>> different models, but in same database. I can create and 
>> platen this 
>>> relationship in EOModler and got AB table as well.
>>> 
>>> AB is in the same DB and only has compound PK like A_ID and B_ID.
>>> 
>>> When I tried to do saveChanges got this error
>>> 
>>> 
>>> [2009-12-15 12:6:48 NZDT] <WorkerThread0> 
>>> java.lang.NullPointerException
>>>        at
>>> com
>>> .webobjects
>>> .eoaccess
>>> .EODatabaseContext
>>> 
>> .primaryKeyForIntermediateRowFromSourceObject(EODatabaseContext.java: 
>>> 4845)
>>> 
>>>        at
>>> com
>>> .webobjects
>>> .eoaccess
>>> .EODatabaseContext
>>> .databaseOperationForIntermediateRowFromSourceObject
>>> (EODatabaseContext.java:4863)
>>> 
>>>        at
>>> com
>>> .webobjects
>>> .eoaccess
>>> .EODatabaseContext
>>> .recordInsertForIntermediateRowFromSourceObject
>>> (EODatabaseContext.java:4888)
>>> 
>>>        at
>>> com
>>> .webobjects
>>> .eoaccess
>>> .EODatabaseContext
>>> .relayAttributesInRelationshipSourceObjectDestinationObject
>>> (EODatabaseContext.java:4913)
>>> 
>>>        at
>>> com
>>> .webobjects
>>> .eoaccess
>>> .EODatabaseContext
>>> .relayAttributesInRelationshipSourceObjectDestinationObjects
>>> (EODatabaseContext.java:4966)
>>> 
>>>        at
>>> com
>>> .webobjects
>>> .eoaccess
>>> .EODatabaseContext
>>> .recordChangesInEditingContext(EODatabaseContext.java:6036)
>>>        at
>>> com
>>> .webobjects
>>> .eocontrol
>>> .EOObjectStoreCoordinator
>>> .saveChangesInEditingContext(EOObjectStoreCoordinator.java:373)
>>> 
>>>        at
>>> com
>>> .webobjects
>>> .eocontrol.EOEditingContext.saveChanges(EOEditingContext.java:3192)
>>> 
>>> 
>>> And I found only updateObjects could has two entities's details and 
>>> insertedObjects does not print out anything.
>>> 
>>> Not sure this does not work in across models or something else need 
>>> setup?
>>> 
>>> thanks
>>> 
>>> 
>>> 
>>> Xiaowen(Kevin) Ren
>>> 
>>> Analyst Programmer
>>> Channel Applications, Retail Applications ANZ National Bank 
>> Ltd Level 
>>> 6 ASB Tower
>>> 2 Hunter Street
>>> PO Box 1791
>>> Wellington
>>> Phone: 04 4365363
>>> Fax: 04 8028696
>>> 
>>> 
>>> 
>>> 
>>> 
>>> "This e-mail and any attachments to it (the "Communication") is, 
>>> unless otherwise stated, confidential,  may contain 
>> copyright material 
>>> and is for the use only of the intended recipient. If you 
>> receive the 
>>> Communication in error, please notify the sender 
>> immediately by return 
>>> e-mail, delete the Communication and the return e-mail, and do not 
>>> read, copy, retransmit or otherwise deal with it. Any views 
>> expressed 
>>> in the Communication are those of the individual sender 
>> only, unless 
>>> expressly stated to be those of Australia and New Zealand Banking 
>>> Group Limited ABN 11 005 357 522, or any of its related entities 
>>> including ANZ National Bank Limited (together "ANZ"). ANZ does not 
>>> accept liability in connection with the integrity of or 
>> errors in the 
>>> Communication, computer virus, data corruption, 
>> interference or delay 
>>> arising from or in respect of the Communication."
>>> 
>>> _______________________________________________
>>> Do not post admin requests to the list. They will be ignored.
>>> Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
>>> Help/Unsubscribe/Update your Subscription:
>>> 
>> http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-v
>>> illage.net
>>> 
>>> This email sent to ch...@global-village.net
>> 
>> -- 
>> Chuck Hill             Senior Consultant / VP Development
>> 
>> Practical WebObjects - for developers who want to increase 
>> their overall knowledge of WebObjects or who are trying to 
>> solve specific problems.
>> http://www.global-village.net/products/practical_webobjects
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
> 
> "This e-mail and any attachments to it (the "Communication") is, unless 
> otherwise stated, confidential,  may contain copyright material and is for 
> the use only of the intended recipient. If you receive the Communication in 
> error, please notify the sender immediately by return e-mail, delete the 
> Communication and the return e-mail, and do not read, copy, retransmit or 
> otherwise deal with it. Any views expressed in the Communication are those of 
> the individual sender only, unless expressly stated to be those of Australia 
> and New Zealand Banking Group Limited ABN 11 005 357 522, or any of its 
> related entities including ANZ National Bank Limited (together "ANZ"). ANZ 
> does not accept liability in connection with the integrity of or errors in 
> the Communication, computer virus, data corruption, interference or delay 
> arising from or in respect of the Communication."
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/mschrag%40mdimension.com
> 
> This email sent to msch...@mdimension.com


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to