is there a way we can query data from non persistent objects on certain selection criteria

0
I am pulling Accounts and Funds data from DB2 database and mapping them into two non  persistent objects in mendix. Now my requirement is that I need to show accounts which are associated with a fund only and I have the fund attributes pulled along with Accounts in the non persistent object. To avoid multiple query execution in DB2 i would like to use the non persistent objects to get the required data . But i am not able to find way to query these non persistent objects. Can someone suggest a way to do this?
asked
3 answers
0

If you hook those non-persistent objects to a users session,

then retrieve in a microflow the full list of the session, and use a filter on that list, and return that resulting list as a data source to a listview/datagrid. will this do what you want it to do?

answered
0

@Michiel Arts

I already did that but now I am getting cross module association error as show in the screen shot

answered
0

You are trying to retrieve the session, though you should retrieve the data you need Account or Fund.

To have a better insight in you Domain model structure and thus the required XPath; NEVER (really just don’t) use an underscore in your entity names. UPT_Account schuld be UPTAccount instead. This will increase the readanbility of your Xpaths and in many case help you to find the right path.

 

EDIT: you are using non-persistend objects, so a database retrieve is not possible. Use retrieve by association and list operations instead

answered