Use the SESSION handle to locate running procedures
- Last Updated: October 14, 2024
- 3 minute read
- OpenEdge
- Version 13.0
- Documentation
There is a very useful built-in handle available globally in your application and, among other
advantages, is one way to identify all running persistent procedures. This is the
SESSION handle. The SESSION
system handle has many attributes and methods, all of which you can learn
about in the ABL Reference. You can also see a list of all
SESSION attributes by accessing the Session Attributes tool in
Progress Developer Studio for OpenEdge ().
Some of these attributes have readable values that are meaningful to you when you look at
them as a list. However, handles are not useful just as numbers (such as the
FIRST-CHILD handle value, shown in the figure).
Your application, however, can make good use of these handles. If you want to examine a
list of all running persistent procedures, you start with the
SESSION:FIRST-PROCEDURE attribute. This attribute evaluates to the
procedure handle of the first of a list of all running procedures. Note that there is no
predictable sequence to the procedures in the list. All you can do is scan the list if
you need to search for a procedure you are interested in. From here, you can walk
through a sequence of all procedures using the NEXT-SIBLING attribute,
which also returns a procedure handle, or with the PREV-SIBLING
attribute if you want to walk backwards through the list. The last procedure in the list
is available using the LAST-PROCEDURE attribute.
|
|
INTERNAL-ENTRIES attribute, and runs the routine it is looking for,
as shown here: