264
Views
5
Comments
Solved
Get Entity Action - Single Attribute
Question

Hello guys

If I use the Get Entity Action this way GetHOME(HomeId).HOME.Altitude which of the following sql queries are executed in db?

 - select Altitude from HOME (only returns the selected value)

 - select Altitude from ( select * from HOME ) aux (returns the full record and then returns the selected attribute)

Thank you

2019-05-22 11-30-09
Marcelo Ferreira
Solution

Hi,

The optimization is framework wide and not only on specific places.

Regards,

Marcelo

2020-06-08 02-42-28
Wasabi

Hi Ruben,

I think OutSystems has been designed to consider performance in mind.

regards,

A

2019-05-22 11-30-09
Marcelo Ferreira

Hi,

The Outsystems compiler optimize the querys in a way that only fetch the values being used. So in that case "select Altitude from HOME" should be the query that is executed in db.

Regards,

Marcelo

2023-02-03 11-00-49
Ruben Bernardo

Marcelo Ferreira wrote:

Hi,

The Outsystems compiler optimize the querys in a way that only fetch the values being used. So in that case "select Altitude from HOME" should be the query that is executed in db.

Regards,

Marcelo


Hello Marcelo,

Does that optimization occurs only in Preparation or does also occur in Actions? I'm using the Get Entity in a general action.

Thanks

2019-05-22 11-30-09
Marcelo Ferreira
Solution

Hi,

The optimization is framework wide and not only on specific places.

Regards,

Marcelo

2025-04-22 05-54-18
Shashi Kant Shukla

Hi Ruben,

This optimization can only work in Preparation and not working in actions that`s why outsystems prefers agregates in Preparation.


Regards

-SK-

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.