Database Reference
In-Depth Information
Next, let's add a Search field to the report to allow users to filter for a specific ticket
they may be interested in. Before you do, here's a brief explanation of session state to
help you understand how APEX keeps track of the values associated with a user's ses-
sion.
Understanding Session State
Session state is what allows APEX to keep track of all the values that belong in a par-
ticular user's APEX session. Session state is particularly useful for keeping track of
values as a user moves from page to page in the application.
Unlike a stateful database application, where a connection is maintained continu-
ously and all values retain their value until changed or removed or until the session
ends, an APEX application doesn't maintain a continuous connection to the database.
APEX is a stateless system—the APEX engine generates HTML pages based on dir-
ectives stored in the APEX repository. Each page-rendering is a stateless transaction.
An APEX session ties the stateless HTML pages together.
An APEX session is logically and physically distinct from the underlying database
sessions. A database session is stateful, and an APEX session is stateless. To illustrate
the difference, think of a database session as a phone call on a land line. The parties are
connected for the duration of the conversation. Both parties have to invest resources to
carry on a conversation. Even if no one is talking, the connection—and the link
between the two parties—remains, as shown in Figure 6-40 .
Figure 6-40. Database session communication
Think of an APEX session as a text message. The parties aren't directly connected;
they push information in one direction at a time, even if the communication is an entire
conversation via a series of texts. Figure 6-41 illustrates APEX stateless session com-
munication.
 
 
 
Search WWH ::




Custom Search