Skip to Content (Press Enter)
OutSystems.com
Personal Edition
Community
Support
Training
Training
Online Training
Developer Schools
Boot Camps
Certifications
Tech Talks
Documentation
Documentation
Overview
ODC
O11
Forums
Forge
Get Involved
Get Involved
Jobs
Ideas
Members
Mentorship
User Groups
Platform
Platform
ODC
O11
Search in OutSystems
Log in
Get Started
Back to Forums
Rui Molefas
0
Views
4
Comments
Performance question
Question
Hello all,
this is probably not my sharpest question but...what is better, to rely on database access or to "walk around" with a number of arguments?
I ask this because in some cases I use an action in a webscreen to query a certain DB to get a certain value, and in the next screens some of the attributes i also got with that query will also be used. Is it better to make queries on each screen to get specific values or, in the first query get all the attributes and pass them onto the next web screens as arguments.
This is merely to increase the performance of my application.
Thank you in advance.
Hermínio Mira
Hi Rui,
In my experience I found out that I prefer to do queries in each screen, the issues I see with using values as parameters:
gets messy really quick (always adding non mandatory input parameters which you then forget what they are supposed to do in a week...)
can lead to "strange" errors in screens just because you forgot to assign a variable in some link
maintainablility is gonna be tough...
new users looking at the code will say "what was this guy thinking when he put 30 input parameters?" :)
Hope it helps,
Hermínio Mira
1 reply
18 May 2012
Show thread
Hide thread
Evert van der Zalm
MVP
Hermínio Mira wrote
:
Hi Rui,
In my experience I found out that I prefer to do queries in each screen, the issues I see with using values as parameters:
gets messy really quick (always adding non mandatory input parameters which you then forget what they are supposed to do in a week...)
can lead to "strange" errors in screens just because you forgot to assign a variable in some link
maintainablility is gonna be tough...
new users looking at the code will say "what was this guy thinking when he put 30 input parameters?" :)
Hope it helps,
Hermínio Mira
Don't forget the security issue (url manupilation).
Ricardo Araújo wrote
:
Rui Molefas wrote
:
in some cases I use an action in a webscreen to query a certain DB to get a certain value, and in the next screens some of the attributes i also got with that query will also be used. Is it better to make queries on each screen to get specific values or...
Rui,
forget the or part. It's better to do simple queries in the screens because the platform will tune the query in order to get only the used attributes in that screen otherwise you'll retrive all attributes in the entities existing in that query.
Cheers,
Ricardo
Ricardo, please don't say it like it's always tuned by the platform, there are some rules before that is done....
Kind regards,
Evert
Ricardo Araújo
Rui Molefas wrote
:
in some cases I use an action in a webscreen to query a certain DB to get a certain value, and in the next screens some of the attributes i also got with that query will also be used. Is it better to make queries on each screen to get specific values or...
Rui,
forget the or part. It's better to do simple queries in the screens because the platform will tune the query in order to get only the used attributes in that screen otherwise you'll retrive all attributes in the entities existing in that query.
Cheers,
Ricardo
Rui Molefas
Thanks a lot for your replies!
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
See the full guidelines
Loading...