In
a program of type VGWebTransaction, the system variable SysVar.sessionID contains
an ID that is specific to the Web application server session. You can use
the SysVar.sessionID value as a key value to access
file or database information shared between programs. A related variable for
VGWebTransaction programs is SysVar.conversationID.
Outside of Web applications, the following statements apply:
- The system variable SysVar.sessionID contains
a system-dependent user identifier or terminal identifier for your program.
In EGL-generated Java™ code, the value is from the Java Virtual
machine property user.name.
- SysVar.sessionID is supported for this use only
for compatibility with products that preceded EGL (specifically, for CSP releases
prior to CSP 370AD Version 4 Release 1). It is recommended that you use SysVar.userID or SysVar.terminalID instead.
You can use SysVar.sessionID in these ways:
- As the source in an assignment or move statement
- As a variable in a logical expression
- As the argument in a return statement
The characteristics of
SysVar.sessionID are as
follows:
- Primitive type
- CHAR
- Data length
- 8 (padded with blanks if the value has less than 8 characters)
- Is value always restored after a converse?
- Yes
SysVar.sessionID is
initialized from the Java Virtual Machine system property user.name;
and if the property cannot be retrieved, SysVar.sessionID is
blank.