Alex,
I created new EC for each Entity instance but I got to messages :
relationship Exception :
java.lang.RuntimeException: You crossed editing context boundaries attempting to set the 'eoTypeTiers' relationship of <org.utt.rfcct.serveur.modele.rfcct.EODomaine pk:"null"> (in EC er.extensions.eof.ERXEC@1be3e4c5) to <org.utt.rfcct.serveur.modele.rfcct.EOTypeTiers pk:"2"> (in EC er.extensions.eof.ERXEC@4dbed348).
at er.extensions.eof.ERXGenericRecord.checkMatchingEditingContexts(ERXGenericRecord.java:1316)
at er.extensions.eof.ERXGenericRecord.addObjectToBothSidesOfRelationshipWithKey(ERXGenericRecord.java:581)
at org.utt.rfcct.serveur.modele.rfcct._EODomaine.setEoTypeTiersRelationship(_EODomaine.java:208)
at org.utt.rfcct.serveur.components.assistants.modules.ModuleAdminDomaine.validerDomaine(ModuleAdminDomaine.java:90)
at org.utt.rfcct.serveur.components.assistants.modules.ModuleAdminDomaine.unDomaineEnregistrer(ModuleAdminDomaine.java:248)
Data save Error :
avr. 03 16:45:52 RFcct[8485] DEBUG er.eo.ERXGenericRecord - EditingContextWillSaveChanges: done calling will*
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Begin Internal Transaction
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - evaluateExpression: <com.webobjects.jdbcadaptor.OraclePlugIn$OracleExpression: "SELECT RFCCT.DOMAINE_SEQ.NEXTVAL FROM DUAL" withBindings: >
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - 1 row(s) processed
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Commit Internal Transaction
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Begin Internal Transaction
avr. 03 16:45:52 RFcct[8485] INFO er.transaction.adaptor.Exceptions - Database Exception occured: java.lang.NullPointerException
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Rollback Internal Transaction
com.webobjects.eoaccess.EOGeneralAdaptorException
at com.webobjects.eoaccess.EODatabaseContext._exceptionWithDatabaseContextInformationAdded(EODatabaseContext.java:4504)
at com.webobjects.eoaccess.EODatabaseContext.performChanges(EODatabaseContext.java:6216)
at com.webobjects.eocontrol.EOObjectStoreCoordinator.saveChangesInEditingContext(EOObjectStoreCoordinator.java:376)
at com.webobjects.eocontrol.EOEditingContext.saveChanges(EOEditingContext.java:3192)
at er.extensions.eof.ERXEC._saveChanges(ERXEC.java:1176)
at er.extensions.eof.ERXEC.saveChanges(ERXEC.java:1099)
at org.utt.rfcct.serveur.components.assistants.modules.ModuleAdminDomaine.unDomaineEnregistrer(ModuleAdminDomaine.java:257)
I created new EC for each Entity instance but I got to messages :
relationship Exception :
java.lang.RuntimeException: You crossed editing context boundaries attempting to set the 'eoTypeTiers' relationship of <org.utt.rfcct.serveur.modele.rfcct.EODomaine pk:"null"> (in EC er.extensions.eof.ERXEC@1be3e4c5) to <org.utt.rfcct.serveur.modele.rfcct.EOTypeTiers pk:"2"> (in EC er.extensions.eof.ERXEC@4dbed348).
at er.extensions.eof.ERXGenericRecord.checkMatchingEditingContexts(ERXGenericRecord.java:1316)
at er.extensions.eof.ERXGenericRecord.addObjectToBothSidesOfRelationshipWithKey(ERXGenericRecord.java:581)
at org.utt.rfcct.serveur.modele.rfcct._EODomaine.setEoTypeTiersRelationship(_EODomaine.java:208)
at org.utt.rfcct.serveur.components.assistants.modules.ModuleAdminDomaine.validerDomaine(ModuleAdminDomaine.java:90)
at org.utt.rfcct.serveur.components.assistants.modules.ModuleAdminDomaine.unDomaineEnregistrer(ModuleAdminDomaine.java:248)
Data save Error :
avr. 03 16:45:52 RFcct[8485] DEBUG er.eo.ERXGenericRecord - EditingContextWillSaveChanges: done calling will*
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Begin Internal Transaction
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - evaluateExpression: <com.webobjects.jdbcadaptor.OraclePlugIn$OracleExpression: "SELECT RFCCT.DOMAINE_SEQ.NEXTVAL FROM DUAL" withBindings: >
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - 1 row(s) processed
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Commit Internal Transaction
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Begin Internal Transaction
avr. 03 16:45:52 RFcct[8485] INFO er.transaction.adaptor.Exceptions - Database Exception occured: java.lang.NullPointerException
avr. 03 16:45:52 RFcct[8485] DEBUG NSLog - === Rollback Internal Transaction
com.webobjects.eoaccess.EOGeneralAdaptorException
at com.webobjects.eoaccess.EODatabaseContext._exceptionWithDatabaseContextInformationAdded(EODatabaseContext.java:4504)
at com.webobjects.eoaccess.EODatabaseContext.performChanges(EODatabaseContext.java:6216)
at com.webobjects.eocontrol.EOObjectStoreCoordinator.saveChangesInEditingContext(EOObjectStoreCoordinator.java:376)
at com.webobjects.eocontrol.EOEditingContext.saveChanges(EOEditingContext.java:3192)
at er.extensions.eof.ERXEC._saveChanges(ERXEC.java:1176)
at er.extensions.eof.ERXEC.saveChanges(ERXEC.java:1099)
at org.utt.rfcct.serveur.components.assistants.modules.ModuleAdminDomaine.unDomaineEnregistrer(ModuleAdminDomaine.java:257)
It's not is to use EC.saveChanges() :(
Thanks
Envoyé depuis iCloud
Le 03 avr 2013 à 07:17, Raymond NANEON <[email protected]> a écrit :
Le 03 avr 2013 à 06:58, Alexis Tual <[email protected]> a écrit :2013/4/3 Raymond NANEON <[email protected]>Bonjour Alexis,
Well come back to cocktail :)
So when I want to set the relationship I got this in stacktrace :
avr. 03 14:16:48 RFcct[8485] INFO er.transaction.adaptor.Exceptions - Database Exception occured: java.lang.NullPointerException
java.lang.NullPointerException
at com.webobjects.jdbcadaptor.OraclePlugIn$OracleExpression.isLOBAttribute(OraclePlugIn.java:531)
at com.webobjects.jdbcadaptor.OraclePlugIn$OracleExpression.shouldUseBindVariableForAttribute(OraclePlugIn.java:547)
at com.webobjects.eoaccess.EOSQLExpression.sqlStringForValue(EOSQLExpression.java:1965)
at com.webobjects.jdbcadaptor.OraclePlugIn$OracleExpression.sqlStringForKeyValueQualifier(OraclePlugIn.java:651)
at com.webobjects.eoaccess.EOQualifierSQLGeneration$_KeyValueQualifierSupport.sqlStringForSQLExpression(EOQualifierSQLGeneration.java:463)
at er.extensions.ERXExtensions$KeyValueQualifierSQLGenerationSupport.sqlStringForSQLExpression(ERXExtensions.java:348)Looks like some attribute in your eomodel doesn't have an External Type set. This is mandatory.
issue corrected, thanks a lot.
I deleted my build directory and clean everything. it seems the instruction domaine.editingContext().saveChanges(); save all EOEntreprises in the context and not domaine Entity only? Why? I want just to save domaine and not all entities like CAPACITE, MATIERE and so one.An editingContext observes all changes from the eo's it "contains", see it as a sandbox. You can't select specific changes. You could use one EC for your "domaine" changes et one EC for the other changes.
So I must create new EC Entity instance ? I try it.
RayAlex
ThanksEnvoyé depuis iCloud
Le 03 avr 2013 à 03:17, Alexis Tual <[email protected]> a écrit :Bonjour Raymond,What's the NPE stacktrace ?the eomodel looks fine too me as it allows null relationship. It seems you have a refresh pb in your eclipse, try to refresh/clean your projects.Cheers,Alex2013/4/3 Raymond NANEON <[email protected]>Hi List,
I have a big problem with my relationship one-to-many.
When I set domaine.setEoTypeTiersRelationship(ctrl.getSelectedTypeTiers()), I got java.lang.NullPointerException and When I dion't set the relationship I got "<er.extensions.validation.ERXValidationException object: <org.utt.rfcct.serveur.modele.rfcct.EODomaine pk:"null">; propertyKey: eoTypeTiers; type: MandatoryToOneRelationshipException; additionalExceptions: ()>".
What I am doing wrong? I try to do domaine.editingContext().saveChanges();
Here is How my relationship look like in model<domaine.jpg><typeTiers.jpg>
Thanks for your advices
Envoyé depuis iCloud
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/alexis.tual%40gmail.com
This email sent to [email protected]
Envoyé depuis iCloud_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/rnaneon%40me.com
This email sent to [email protected]
_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]
