
- #HOW TO GET SYSTEM DATE IN CL PROGRAM MANUAL#
- #HOW TO GET SYSTEM DATE IN CL PROGRAM CODE#
- #HOW TO GET SYSTEM DATE IN CL PROGRAM DOWNLOAD#
Wa_output2-/bic/z_marks3 = 'Subject Marks3'.ĬLEAR wa_output2. Wa_output2-/bic/z_marks2 = 'Subject Marks2'. Wa_output2-/bic/z_marks1 = 'Subject Marks1'. DATA: it_output2 TYPE STANDARD TABLE OF ty_output2, **To display the header in the file, we need to append the data required, as mentioned in the below code. It_output TYPE STANDARD TABLE OF ty_output, **Declaration of data specifying the name of the path where the downloaded file is to be placed. Zmarks3 TYPE /bic/oiz_marks3, END OF ty_output, BEGIN OF ty_output2, * Declaration of necessary fields *TYPES: BEGIN OF ty_output,
#HOW TO GET SYSTEM DATE IN CL PROGRAM DOWNLOAD#
To download the excel file and place it in a specified path.
#HOW TO GET SYSTEM DATE IN CL PROGRAM CODE#
Copy and paste the below code in the ABAP editor and save. Now the ABAP editor is in front of you. Go ahead providing a new Transport request or assign an old transport request if exists and click ok to move ahead.

Fill the required fields with the package name which you use in your project. Now it prompts to save this program in a package. Give the necessary title and the Attributes (Type, Status etc.). Create an executable program ZTEST_FILE_DNLD. Step-by-Step Procedure for Implementing the Program Note: The Table or ODS or Infoobject which we are using should be readily available in BW. Ø The excel file can be sent as an attachment to many number of mail id's marking them in Copy and Blind Copy too. Ø The excel file will be downloaded and placed in a specified path (either in Local machine or Application server path or Network area path) Ø This program fetches the data from a table and places it in an excel file. These two scenarios are achieved with the help of an ABAP Executable program. The second scenario is that we will send the same excel file as an attachment without downloading it to our local machine which will be automated. The first scenario specifies to download the data in the excel sheet and place that in a specified path - the student's data will be placed retrieving the necessary data from an ODS and then download, place the excel file in a specified path present in your local machine. To convey the same, I have considered two business scenarios. So in order to generate a report and export the same to an excel file automatically and place it in the specified path (either local machine path or Application server path or Network path) and also to send the excel file as an attachment to different mail id's, we need to follow the below process.
#HOW TO GET SYSTEM DATE IN CL PROGRAM MANUAL#
To generate the report and perform Export to Excel file and to send the file to user mail box, much manual intervention is necessary. In our daily scenario's, we need to send BI reports to Top level Management or Middle Level Management users. We can also automate the process of sending the excel file as an attachment in the mail and send it to as many mail id's as required.

Now by using this ABAP executable program, we can generate a file in excel format with the required fields and place that particular file in a specified path required. In SAP BW, using Open Hub, we can generate a CSV formatted file and place that in the required path (either Application server or local machine). Skill set includes SAP Business Intelligence, SAP POS, SAP Integrated Planning and Business Objects.

Koundinya Karanam is a SAP BI Consultant working for Mahindra Satyam. This document guides the user to generate an ABAP executable program which helps the user to create an excel file, fill it with necessary data and then place that particular excel formatted file in the path required. For more information, visit Business Intelligence homepage.
