You are on page 1of 5

Open datasets, Read datasets ( Reading and writing data to files) By: rekha | 17 Feb 2008 9:28 am | 11 times

viewed | 0 Comments Date Sets are nothing but files on Application Server,they can even be called as Sequential files. Open Dataset Is used to open required file on the application Server. Read Dataset. Is used to read the contents required file on the application Server. ////////////////// Function modules - System By: saketpratap | 27 Apr 2007 10:58 am | 28 times viewed | 0 Comments 1. Directories and files 2. Output and spool 3. Logs 4. FTP 5. Others 1. Directories and files RZL_READ_DIR_LOCAL - Read a directory on the Application Server RZL_READ_DIR - If the server name is left blank, it reads a directory from local presentation server, otherwise it reads the directory of the remote server EPS_GET_DIRECTORY_LISTING - return a list of filenames from a local or network d rive 2. Output and spool SO_SPOOL_READ - Fetch printer spool according to the spool number informed. SO_WIND_SPOOL_LIST - Browse printer spool numbers according to user informed. 3. Logs BP_JOBLOG_READ - Fetch job log executions. 3.1 Application log APPL_LOG_DELETE With this function module you delete logs in the database accord ing to specified selection conditions APPL_LOG_DISPLAY With this function module you can analyze logs in the database. APPL_LOG_DISPLAY_INTERN With this function module you can analyze logs in local memory, e.g. when you have only collected log records at runtime and do not want to write to the database. APPL_LOG_INIT This function module checks whether the specified object or sub-ob ject exists and deletes all existing associated data in local memory. APPL_LOG_READ_DB With this function module you read the log data in the database for an object or sub-object according to specified selection conditions. APPL_LOG_READ_INTERN With this function module you read all log data whose log c

lass has at least the specified value, from local memory, for the specified obje ct or sub-object. APPL_LOG_SET_OBJECT With this function module, you create a new object or sub-ob ject for writing in local memory. With a flag you can control whether the APPL_LOG_WRITE_... messages are written in local memory or are output on the scr een. APPL_LOG_WRITE_DB With this function module you write all data for the specified object or sub-object in local memory to the database. If the log for the object or sub-object in question is new, the log number is returned to the calling program . APPL_LOG_WRITE_HEADER With this function module, you write the log header data i n local memory. APPL_LOG_WRITE_LOG_PARAMETERS With this function module, you write the name of t he log parameters and the associated values for the specified object or sub-object in local memory. If this function module is called repeatedly for the same object or sub-object, the existing parameters are updated accordingly. If you do not specify an object or sub-object with the call, the most recently used is assumed . APPL_LOG_WRITE_MESSAGE_PARAMS With this function module you write a single messa ge, with parameters, in local memory. Otherwise the function module works like A PPL_LOG_WRITE_SINGLE_MESSAGE. APPL_LOG_WRITE_MESSAGES With this function module you write one or more messages , without parameters, in local memory. APPL_LOG_WRITE_SINGLE_MESSAGE With this function module you write a single messa ge, without parameters, in local memory. If no header entry has yet been written for the object or sub-object, it is created. If you do not specify an object or sub-object with the call, the most recently used is assumed. BAL_CNTL_CREATE Create Control for log display BAL_CNTL_FREE Release Control BAL_CNTL_REFRESH Put new data in log display BAL_DB_DELETE Delete logs from the database BAL_DB_DEQUEUE Unlock log BAL_DB_ENQUEUE Lock log BAL_DB_LOAD Load logs from the database BAL_DB_LOAD Load log(s) BAL_DB_SAVE Save logs in the database BAL_DB_SAVE Save log(s)

BAL_DB_SAVE_PREPARE Prepare save BAL_DB_SEARCH Find logs in the database BAL_DSP_LOG_DISPLAY Display messages in memory BAL_DSP_LOG_DISPLAY Display Log BAL_DSP_LOG_PARAMETERS Either output extended long text or call a callback routi ne (based on the data in BAL_S_LOG-PARAMS) BAL_DSP_LOG_TECHNICAL_DATA Output all log header data BAL_DSP_MSG_LONGTEXT Display message long text BAL_DSP_MSG_PARAMETERS Either output extended long text or call a callback routi ne (based on the data in BAL_S_MSG-PARAMS) BAL_DSP_MSG_TECHNICAL_DATA Output technical data of a message such as work area, error number, etc. BAL_DSP_OUTPUT_FREE End output BAL_DSP_OUTPUT_INIT Initialize output BAL_DSP_OUTPUT_SET_DATA Set dataset to be displayed BAL_DSP_PROFILE_DETLEVEL_GET Message hierarchy in DETLEVEL BAL_DSP_PROFILE_NO_TREE_GET Display without tree (fullscreen) BAL_DSP_PROFILE_POPUP_GET Display without tree (popup) BAL_DSP_PROFILE_SINGLE_LOG_GET Standard profile (SLG1) for one log BAL_DSP_PROFILE_STANDARD_GET Standard profile (SLG1) for a lot of logs BAL_GLB_AUTHORIZATION_GET Assign authorization BAL_GLB_AUTHORIZATION_RESET Reset authorization BAL_GLB_CONFIG_GET Read configuration BAL_GLB_CONFIG_SET Set configuration BAL_GLB_MEMORY_EXPORT Put function group memory in ABAP-MEMORY BAL_GLB_MEMORY_IMPORT Get function group memory from ABAP-MEMORY BAL_GLB_MEMORY_REFRESH (Partially) reset global memory BAL_GLB_MEMORY_REFRESH (Partially) initialize memory BAL_GLB_MSG_CURRENT_HANDLE_GET Get current message handle BAL_GLB_MSG_DEFAULTS_GET Get message defaults BAL_GLB_SEARCH_LOG Find logs in memory

BAL_GLB_SEARCH_MSG Find messages in memory BAL_LOG_CREATE Create log with header data BAL_LOG_CREATE Create log with header data BAL_LOG_DELETE Delete log (from database also at Save) BAL_LOG_EXIST Check existence of a log in memory BAL_LOG_HDR_CHANGE Change log header BAL_LOG_HDR_CHECK Check log header data for consistency BAL_LOG_HDR_READ Read log header and other data BAL_LOG_MSG_ADD Put message in log BAL_LOG_MSG_ADD Put message in log BAL_LOG_MSG_CHANGE Change message BAL_LOG_MSG_CHANGE Change message BAL_LOG_MSG_CHECK Check message data for consistency BAL_LOG_MSG_CUMULATE Add message cumulated BAL_LOG_MSG_DELETE Delete message BAL_LOG_MSG_DELETE Delete message BAL_LOG_MSG_EXIST Check existence of a message in memory BAL_LOG_MSG_READ Read message and other data BAL_LOG_MSG_REPLACE Replace last message BAL_LOG_REFRESH Delete log from memory BAL_LOG_REFRESH Delete log from memory 4. FTP FTP_CONNECT - Open a connection (and log in) to an FTP server FTP_COMMAND - Execute a command on the FTP server FTP_DISCONNECT - Close the connection (and log off) the FTP server 5. Others TERMINAL_ID_GET - Return the terminal id TH_ENVIRONMENT - Get the UNIX environment TH_POPUP - Display a popup system message on a specific users screen. TH_REMOTE_TRANSACTION - Run a transaction on a remote server. Optionally provide

BDC data to be used in the transaction TH_USER_INFO - Give information about the current user (sessions, workstation lo gged in from, etc) TH_USER_LIST - Show which users are logged into an app server WS_EXECUTE - execute a program on a windows PC WS_VOLUME_GET - Get the label from a frontend device. BP_EVENT_RAISE - Trigger an event from ABAP/4 program. ARFC_GET_TID will return the IP address of the terminal in hex. ENQUEUE_ESFUNCTION Lock an abap program so that it cannot be executed. Example: Set the parameters as follows: RELID = 'ZZ' SRTF2 = 0 SRTF = (your report name) Please note that you should not use SY-REPID to pass your report name to the fun ction. The value of SY-REPID will change as it is being passed to the function m odule, and will no longer hold the value of the calling report.

You might also like