How are session variables retrieved?
Application Type
Traditional Web

Hi all,

Was curious to know how are session variables retrieved, using the beneath example:

1 - Everytime the page loads, will the 4 session variables be retrieved one-by-one, or will the values of these variables be retrieved all in the same request?

2 - In the case of 'ProfileModalInput' which is a structure, will it also fetch each of the structure's attributes in the same request as all the other session variables?

Thanks in advance.

Rank: #54

Hi Ricardo,

Session variables apply only in Traditional Web and are stored in a Session database catalog, apart from the OutSystems database catalog which stores the metamodel of the application and your applicational data.

This data is retrieved when the user starts a session and is sent to the server on every request you make (also on each AJAX refresh) which is the reason why you should keep it to a minimum and avoid heavy data types like Lists since they impact your Traditional Web application on every request.

For more information, see here the full documentation about Session variables.


Thanks João, 

So just to be sure I understood your answer: all the session data is retrieved from the session database catalog all in the same query for the logged in user, everytime he or she reloads the page or on each ajax refresh?

PS: you forgot to add the link :) 

Rank: #54

Hi Ricardo,

Yes, that is correct, the whole data goes back and forward in every request.

Sorry, I have updated the previous answer to include the link.

Rank: #87


you need to set value in this session when after successful login.

and you can access this session anywhere in application.