Previous Page | Next Page

Functions and CALL Routines

SYSPROCESSID Function



Returns the process ID of the current process.
Category: Special

Syntax
Details
Examples
Example 1: Using a DATA Step
Example 2: Using SAS Macro Language
See Also

Syntax

SYSPROCESSID()


Details

The SYSPROCESSID function returns the 32-character hexadecimal ID of the current process. This ID can be passed to the SYSPROCESSNAME function to obtain the name of the current process.


Examples


Example 1: Using a DATA Step

The following DATA step writes the current process id to the SAS log:

data _null_;
   id=sysprocessid();
   put id;
run;


Example 2: Using SAS Macro Language

The following SAS Macro Language code writes the current process id to the SAS log:

%let id=%sysfunc(sysprocessid());
%put &id;


See Also

Function:

SYSPROCESSNAME Function

Previous Page | Next Page | Top of Page