Hi CUBA Team,
I’ve got a requirement where I want to be able to show de-normalized data in a screen for the user to select. Say I have a schema that is Customer, Order, and Product tables. A Customer has Orders and an Order has Products. I need to be able to show a list of every Customer, Order, and Product combination in one grid. I’ve created a non-persistent entity for this with associations to Customer, Order, and Product as properties but I’m unsure of the best way to populate it without having to do a lot of selectById calls.
I’m thinking it might be better to just work with simple data types (Customer.id, Customer.name, Order.id, Order.name, etc) on my non-persistent entity instead of associations, making the select query easier, but I wanted to see if there’s a more recommended approach.
Thanks as always.