Retrieving an entity from the database will only retrieve that entity, no associated records. You can imagine that a simple retrieve of Customer could end up retrieving a ton of data if it also automatically pulled order, the items on those orders, the details of payment, the related inventory records, etc, etc.
Yes, after pulling from db if you then pull by association it will go back to the db, assuming some other step had not causes it to be retrieved.
Hi Patrick,
If it helps:
https://www.auraq.com/retrieving-data-in-mendix
https://docs.mendix.com/refguide/retrieve
We must also remember, that there is a efficient caching layer developed in mendix to optmise the performance of application.
I am also currently working with the same things for my product.
Regards,
Nirmal
UPDATE: 24th June
Patrick, as said I am also currently working with some similar task. During this, I observed the following:
I was using the query to observe the queries: SELECT query FROM pg_stat_activity where datname = '<DB name>' and client_addr = '<host>';
I hope this helps further. Will keep you posted if I have additions to this.