Hi Yizuhi,
Depending on the type of data, you may not want to store them in client variables because they can be tempered and it is not secure. For instance, if you have a flag CanEdit or a role that may be changed by an attacker, or a password to access confidential data, you DO NOT want to have this information as a client variable.
In that case, you want to save them in the database.
You can read more about client variables and the above information in the OutSystems documentation here.
If it is a simple query you should not have a problem of performance. You also can decide to cache the query if the settings are rarely changed to avoid going to the database every time. You would need to invalidate cache when you change those settings. You can read about how caching works in OutSystems here.
Hope it helps.
Kind Regards,
João