An extended stored procedure (ESP) lets you call external language functions from within SAP ASE.
SAP ASE includes a set or predefined ESPs; users can also create their own. The names of all system extended stored procedures begin with “xp_”, and are located in the sybsystemprocs database.
One very useful system ESP is xp_cmdshell, which executes an operating system command on the system that is running SAP ASE.
Invoke a system ESP just like a system procedure. The difference is that a system ESP executes procedural language code rather than Transact-SQL statements. All ESPs are implemented by an Open Server™ application called XP Server™, which runs on the same machine as SAP ASE. XP Server starts automatically on the first ESP invocation.
For information about the system ESPs provided with SAP ASE, see the Reference Manual: Procedures.