for explaining sake im using this examples
Let's say
local!role : index( local!lookupDetails, wherecontains( cons!IHL_TXT_R_ALL_CATEGORIES[1], index( local!lookupDetails,"role" null ) ) )
i need to use one values from the record in my UI many places
for that can i hold it in one local and pass wherever needed.
or can i use it directly wherever i needed
if so i need to call index,whereconains in many places right dont it consume memory
and it will make the code repetitive lines get increasewhat is the best practice.
Discussion posts and replies are publicly visible
If I need a computed value multiple times, I use local variables to reduce the evaluation time.
if no need of compute ?
Dinesh Arumugam said:if so i need to call index,whereconains in many places right dont it consume memory
This what compute means in your case. We generally go with first approach it's best practice not only in Appian but in other coding languages too
compute means - doing some operations and getting some value
yes we use the first approach, but it consume memory right ,that why i raised this question