Xpath as datasource to datagrid is throwing error

0
  I am using one xpath constraint to datagrid in home page. On first its working fine, but after updating any record of that datasource entity user is redirected to home page and it throws the below error. Error Message:   com.mendix.core.CoreRuntimeException: Exception occurred in action '{"xpath":"//CoreBuisness.InVoice","amount":10,"offset":0,"returnsCount":true,"sort":[{"memberName":"","direction":{}}],"type":"RetrieveXPathSchemaRawAction"}', all database changes executed by this action were rolled back  at com.mendix.basis.actionmanagement.CoreActionHandlerImpl.processErrorState(CoreActionHandlerImpl.scala:153) Caused by: com.mendix.connectionbus.ConnectionBusRuntimeException: An exception has occurred for the following request(s):  InternalLimitedXPathTextGetRequest (depth = -1, amount = 10): //CoreBuisness.InVoice  at com.mendix.connectionbus.RequestAnalyzer.doRequest(RequestAnalyzer.scala:35) Caused by: com.mendix.connectionbus.ConnectionBusRuntimeException: Can't find alias with name '' in empty context and can't find attribute with name '' in entity 'CoreBuisness.InVoice' while parsing path ''  at com.mendix.connectionbus.retrieve.OqlRequestHandler.doNewQueryHandling(OqlRequestHandler.scala:157) Caused by: com.mendix.datastorage.dependentqueries.QuerySchemaValidationException: Can't find alias with name '' in empty context and can't find attribute with name '' in entity 'CoreBuisness.InVoice' while parsing path ''  at com.mendix.datastorage.dependentqueries.QuerySchemaInterpreter$Implicits$RetrievalSchemaExtension$.toQuerySchema$extension(QuerySchemaInterpreter.scala:92)  at com.mendix.datastorage.handler.CachedTransformationSteps$.$anonfun$withDependentQueries$5(QueryHandler.scala:174)  at scala.Option.map(Option.scala:242)  at com.mendix.datastorage.handler.CachedTransformationSteps$.schema$2(QueryHandler.scala:174)  at com.mendix.datastorage.handler.CachedTransformationSteps$.withDependentQueries(Que
asked
3 answers
0

Hey Abraheem,

 

Do you have security enabled in your project? If so, can you share the entity access on your InVoice object for the role you are trying to view the page with?

answered
0

Hello Abraheem,

 

Do you use any event handlers in your domain model like for example a before commit?

 

If so you, you want to make sure to have your error handling properly set like for example handling empty or null.

answered
0

Thanks for the reply. Its resolved. Actually the container wrapping data-grid was
 visible based on an expression. I just used visiblity expression in datagrid itself and removed expression from container.Thanks for the reply. Its resolved. Actually the container wrapping data-grid was
 visible based on an expression. I just used visiblity expression in datagrid itself and removed expression from container.

answered