Error in Expense App

0
Hi all, im getting an error when im trying to create an account in Expense app which uses a microflow SaveNewAccount . Can anypne please help?   An error has occurred while handling the request. [User 'demo_administrator' with session id 'bdef04b8-XXXX-XXXX-XXXX-XXXXXXXX8501' and roles 'Administrator'] -------- com.mendix.webui.WebUIException: Exception while executing runtime operation    at com.mendix.webui.actions.client.RuntimeOperationAction.apply(RuntimeOperationAction.scala:72) Caused by: com.mendix.modules.microflowengine.MicroflowException: Failed to commit    at Administration.SaveNewAccount (Change : 'Set password and save account') Advanced stacktrace:    at com.mendix.modules.microflowengine.MicroflowUtil.processException(MicroflowUtil.java:83) Caused by: com.mendix.core.CoreRuntimeException: Failed to commit    at com.mendix.basis.component.TransactionCore.doCommit(TransactionCore.scala:164)   Caused by: com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.core.CoreException: com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.basis.connectionbus.ConnectionBusException: Exception occurred while inserting data. (SQL State: 23503, Error Code: -177) Detail Message: org.hsqldb.HsqlException: integrity constraint violation: foreign key no parent ; "frn_expenses$teammember_profilepicture_expenses$profilepictureid" table: "expenses$teammember_profilepicture" value: 7599824371316450    at com.mendix.basis.actionmanagement.ActionManager.executeSync(ActionManager.scala:108)   Caused by: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.core.CoreException: com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.basis.connectionbus.ConnectionBusException: Exception occurred while inserting data. (SQL State: 23503, Error Code: -177) Detail Message: org.hsqldb.HsqlException: integrity constraint violation: foreign key no parent ; "frn_expenses$teammember_profilepicture_expenses$profilepictureid" table: "expenses$teammember_profilepicture" value: 7599824371316450    at com.mendix.util.classloading.Runner$.withContextClassLoader(Runner.scala:23)   Caused by: com.mendix.core.CoreException: com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.basis.connectionbus.ConnectionBusException: Exception occurred while inserting data. (SQL State: 23503, Error Code: -177) Detail Message: org.hsqldb.HsqlException: integrity constraint violation: foreign key no parent ; "frn_expenses$teammember_profilepicture_expenses$profilepictureid" table: "expenses$teammember_profilepicture" value: 7599824371316450    at com.mendix.basis.actionmanagement.SyncEventExtendedAction.executeAction(SyncEventExtendedAction.scala:30) Caused by: com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.basis.connectionbus.ConnectionBusException: Exception occurred while inserting data. (SQL State: 23503, Error Code: -177) Detail Message: org.hsqldb.HsqlException: integrity constraint violation: foreign key no parent ; "frn_expenses$teammember_profilepicture_expenses$profilepictureid" table: "expenses$teammember_profilepicture" value: 7599824371316450    at com.mendix.basis.actionmanagement.ActionManager.executeSync(ActionManager.scala:108)   Caused by: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.basis.connectionbus.ConnectionBusException: Exception occurred while inserting data. (SQL State: 23503, Error Code: -177) Detail Message: org.hsqldb.HsqlException: integrity constraint violation: foreign key no parent ; "frn_expenses$teammember_profilepicture_expenses$profilepictureid" table: "expenses$teammember_profilepicture" value: 7599824371316450    at com.mendix.util.classloading.Runner$.withContextClassLoader(Runner.scala:23)   Caused by: com.mendix.basis.connectionbus.ConnectionBusException: Exception occurred while inserting data. (SQL State: 23503, Error Code: -177) Detail Message: org.hsqldb.HsqlException: integrity constraint violation: foreign key no parent ; "frn_expenses$teammember_profilepicture_expenses$profilepictureid" table: "expenses$teammember_profilepicture" value: 7599824371316450    at com.mendix.connectionbus.util.SqlExceptionUtils$.getDetailedException(SqlExceptionUtils.scala:18)  
asked
3 answers
1

Did you change the association in your domain model from 1-* / *-* to 1-1? Is it happening on your local environment?

 

If it's happening local, I would suggest to clear your database, so you will start with new data. I think this will solve your problem. Stop your Mendix runtime. Go to 'App' in the topbar and select 'Show App Directory in Explorer'. Delete your deployment folder and run your app again.

answered
0

I had this issue and it drove me nuts. Completely blew away the association and even the objects referred to in the error message. Nothing after hours. After beginning it turns out the problem was occuring on a change activity that had nothing to do with the association in the stack trace. 

 

Ultimately I was changing an object and setting the association TWICE in the same action

answered
0

I think it's failing to commit the transaction when trying to save the new account and set the password. 

You can check the security rights and try again.

answered