SAP Note 18273 - DELETE DATASET returns SY-SUBRC = 4

Component : ABAP Runtime Environment -

Solution : https://service.sap.com/sap/support/notes/18273 (SAP Service marketplace login required)

Summary :
When using the DELETE DATASET ABAP/4 command, SY-SUBRC may return a value of 4, indicating the file could not be deleted. This can occur for various reasons, such as the file not existing, the intended target being a directory, or lack of necessary read/write permissions. Additional issues might include problems with search paths, symbolic link loops, or attempts to delete files that are currently running. Understanding the specific context and ensuring the correct file path and permissions are crucial for resolving these issues and ensuring proper file management in the SAP environment.

Key words :
abap/4 language element           delete dataset <file_name>, sets sy-subrc, additional key words, sap system, search path, write access, symbolic link, prerequisites, directory3, directory6

Related Notes :

27Recommendations for the ABAP file interface