Hi all,
In Appian, we can create queries directly in a UI, in local variables, or in a process model using script tasks, through rules, and also in node inputs as well. What is the best way to handle them? have come across one such question which I was not sure of.
Discussion posts and replies are publicly visible
I typically wrap each query into a separate expression for ease of debugging and testing. Then I use this wherever necessary.
In interfaces we typically use local variables to store the output. If data is needed in a process, then do that in a script task.
Does that answer your question?
There is nothing best but I would say most efficient way is to create rule due to following reasons1. One place change - Change in the rule reflects at all dependent objects2. Reusability - Can be used at many places
Thank you Stefan and Dhananjay, does querying directly in an interface and the one from the script task have a different impact on performance?
I guess it would be the ways how it execute, like if its under rule then it first render rule and then parent rule, if its directly on interface it does not do so like that.Could you please tell what exactly you're looking for?
Thats just two different things. If you need the data in process, then do that in a script task. If the data is just needed to be displayed to a user, then do it in the interface. Typically you will do a mix of both.
The scenario is to show a read-only grid based on a query. The query can be passed from a script task to UI or directly call in the interface under the data parameter. What should be best considering performance?
Appian is evolving each day and lot of new features adding up.You can put your query in a rule and use in the data parameter of the read-only grid function.