+ All Categories
Home > Documents > SAP BODS - Beginner

SAP BODS - Beginner

Date post: 02-Jun-2018
Category:
Upload: pankaj-k-goel
View: 544 times
Download: 47 times
Share this document with a friend

of 46

Transcript
  • 8/11/2019 SAP BODS - Beginner

    1/46

    SAP BODS - Beginners guide

    AIM:- The purpose of the tutorial is to give a novice a good hands experience on BODS product to beable to create his/her own local repository , configure job server, start his basic job development andexecute the job to extract data from source systems and load data to target systems after performingtransformations, look-ups and validations.

    What is BODS:- It is an ETL tool currently acquired by SAP used for integration with all types of disparatesystems, extracting data from them, transforming them into meaningful information and loading them intoall types of systems.

    It is tightly integrated with SAP systems and hence really a good tool to migrate data from legacy systemsto SAP systems with ease and less development efforts with effective debugging and monitoringcapabilities.

    How to get started ? :-

    After getting BODS installed on the machine, you can see the following on Start>All Programs

    There are several components installed as part of SAP BODS 3.2 installation.

    In the recent release like SAP BODS4, there has been improvements on the architecture , componentsand the enhancement features in several transforms.

    However, the BODS Designer looks pretty same on both 3.2 and 4.0 versions.

    The major enhancement is in the Validation Transform in 4.0 which facilitates developers to switch on andoff the validations flags easily for one or several columns.

    What to launch next- Normally, the developers would like to start BODS Designer to start developing

    jobs straightaway, but it is always good to start creating own local repository first so that you have fullcontrol on your own development environment without any dependency on others.

    In order to create your own local repository, it is important to know the database where you are allocatedspace quota to create the same.

    It depends on the database vendor like Oracle, SQL Server, Informix, DB2, etc which you have currentlyaccess to.

  • 8/11/2019 SAP BODS - Beginner

    2/46

    However, BODS installation comes with default mySQL database, which you should have installed onyour system.

    There is need of user/schema and database creation on my SQL which can be easily done by DBA.

    Once user /schema and database name information is assigned to you, you can create the local

    repository.

    Next Screen shows the BODS Repository Managerwhich administers you to create local repository.

    As you need to create your own local repository to do your own development activities, you need to select

    the Repository type as Local.

  • 8/11/2019 SAP BODS - Beginner

    3/46

  • 8/11/2019 SAP BODS - Beginner

    4/46

    Now you need to choose the Database Type/vendor, where you want to create repository on.

    Since as mentioned earlier, mySQL database comes shipped with BODS product, it is convenient tocreate repository on the same.

    Hence, choose MySQL in Database type.

  • 8/11/2019 SAP BODS - Beginner

    5/46

    MySQL Database type requires you to choose ODBC data source.

    Therefore, you just need to configure ODBC with necessary parameters.

    All you should know is your user name and password and database schema name.

    Next screen helps you how to configure ODBC datastore:-

    Launch ODBC from Control Panel>Administration tools>ODBC

  • 8/11/2019 SAP BODS - Beginner

    6/46

    Go to System DSN tab.

  • 8/11/2019 SAP BODS - Beginner

    7/46

    You can find several default added DSN names.

    If you want a dedicated DSN for yourself, you should be able to add yours.

    Click on Add button.

    Select the driver MySQL ODBC.( Please note that the version can be different, hence you need to askadmin team if there is any discrepancy, but all what you want is mySQL driver).

  • 8/11/2019 SAP BODS - Beginner

    8/46

    Now, you need to supply information as below:

    Data Source Name( it can be as per your desired name).

    Server name- local

    User-(as given by DBA)

    Password (as given by DBA)

    Database (as given by DBA)

    After having provided all the information , you would like to go for testing the connection.

    So, click on Test button

  • 8/11/2019 SAP BODS - Beginner

    9/46

    You can see your newly created DSN name in the screen below.

    Now, launch again the Repository Manager and check in ODBC drop-down for newly created DSN name.

  • 8/11/2019 SAP BODS - Beginner

    10/46

    If the name is not visible, then you need to go to ODBC again and re-configure.

    If it is listed now, you can proceed with the next steps.

  • 8/11/2019 SAP BODS - Beginner

    11/46

    You again need to provide all the mySQL login credentials and database name above as you did earlierfor DSN configuration.

    Select the flag Show details. It gives you all the information wha t version it is and all the other detailswhen you start creating local repository.

    Now, hit the Create button.

    You need to wait for some time for the repository to be created.

    Follow the next screen.

  • 8/11/2019 SAP BODS - Beginner

    12/46

    You should see that local repository was successfully created

  • 8/11/2019 SAP BODS - Beginner

    13/46

    You can check for the version of the repository as well by hitting Get Version.

    Now, it is time for the most important work.

    You need to launch BODS Designer to start your development activities.

    Go to All Programs>SAP Business Objects XI 3.2>sap Business Objects Data Services>Data ServicesDesigner

  • 8/11/2019 SAP BODS - Beginner

    14/46

    Provide all the information you used in creating local repository a while ago.

    Now, you get the screen layout.

    There are basically three important areas you need to undertand.

  • 8/11/2019 SAP BODS - Beginner

    15/46

    1) Local Object Library:- It contains all the necessary objects used for the development of jobs.

    2) Project Area:- It contains all the jobs which are ready for execution or you are currently working on.

    3) Workspace area: The bigger space, where you actually design your job.

    Start development

    Right on empty space in local object area/click on Create Project under Getting Started in the mainpage.

    Create with any name like above

    You can find it in the top left pane (project area).

  • 8/11/2019 SAP BODS - Beginner

    16/46

    Right click on the project name and select new Batch Job.

    Give any name to the new job as shown.

  • 8/11/2019 SAP BODS - Beginner

    17/46

    The job is created.

    No, it is not!!!

    You need to create dataflow under it.

    On the right hand side, you can see the list if icons.

    You click-once the dataflow and click-once on the workspace area (bigger area)

  • 8/11/2019 SAP BODS - Beginner

    18/46

    Name the dataflow as per your wish. It should start with DF_.

    Now, you need to define the source structure.

    In this example, we are using the flat file as source. So, we will create flat file format.

  • 8/11/2019 SAP BODS - Beginner

    19/46

    Go to formats tab in local object library as below:-

    Right click on the flat file and select new.

  • 8/11/2019 SAP BODS - Beginner

    20/46

  • 8/11/2019 SAP BODS - Beginner

    21/46

    You will get the File Format Editor as shown above.

    Now, you need to define the structure of the input file.

  • 8/11/2019 SAP BODS - Beginner

    22/46

    In this example, the input file has 3 fields EMP_ID,EMP_NAME and EMP_DEPT.

    Click under the field name and add the field names.

    Under Data type choose relevant datatype like int for EMP_ID, varchar for EMP_NAME etc.

    In the left hand side, click on Root directory folder to browse to the correct path where the input file is

    placed .

    Click on File name(s) and you should be able to browse to see the input file.

    Follow the next subsequent screens.

  • 8/11/2019 SAP BODS - Beginner

    23/46

    In this example, the input file is a text file which has 2 records as shown below:-

  • 8/11/2019 SAP BODS - Beginner

    24/46

    The text file contains the first row as header defining the field types.

    The next 2 rows contain data.

    Since, we already defined the flat file format structure with field names, we can ignore the first row header(shown in the next screen)

  • 8/11/2019 SAP BODS - Beginner

    25/46

    When you try to save and close the file format editor, it gives you the above warning.

    If you have defined the structure with field names in your file format editor, you should select no, else itwill overwrite with input file provided in the file name.

    Here, you select no.

    Ignoring the row header

    Now, since we have already defined the file format with our field names, we do not require the row headerprovided in the input file.

    So, ignore the row header. See the next screen.

  • 8/11/2019 SAP BODS - Beginner

    26/46

    You find the flat file format created as shown above.

  • 8/11/2019 SAP BODS - Beginner

    27/46

    Now, you need to use this file format as source in your data flow.

    Drag and drop the file format in the workspace area and make it as source.

    Click once on the Query icon on the right hand side and click once on the workspace.

  • 8/11/2019 SAP BODS - Beginner

    28/46

    Name the query and join it to the source file format.

    Now, you need to define the target.

    In this example, we are loading to table.

    So, we need to create a datastore(logical connection to database).

  • 8/11/2019 SAP BODS - Beginner

    29/46

    Go to datastores tab in local object library and right click on the blank space.

    You will get the above screen where you need to provide inputs.

    Datastore name:- as per your choice.

    Datastore type;-Database

    Database type:-mySQL( in this case, as we are using my SQL database for staging tables)

  • 8/11/2019 SAP BODS - Beginner

    30/46

    All over again, you need to provide all login credentials and database name as you provided earlier forcreating local repository.

    If you are using another database for staging tables, you can use information provided by the DBA.

  • 8/11/2019 SAP BODS - Beginner

    31/46

    You see the datastore created.

    Now, you click once on the template table icon in the right hand side and click once on the workspace

  • 8/11/2019 SAP BODS - Beginner

    32/46

    You need to define the name of the target table as per your wish.

    Click on OK

    Now, join the query transform icon to the target.

    But, we have not still mapped the fields from source to target.

    Click on the name of the query.

  • 8/11/2019 SAP BODS - Beginner

    33/46

    You will find that, there are three fields in the source.

    You would like to map all the three fields from source to target

    Drag and drop each field from left pane to right pane one by one.

    Now, try to validate that the design has any errors or warnings

    Click on validate current icon

  • 8/11/2019 SAP BODS - Beginner

    34/46

    If you get the following warnings

    [Source File:"EMPLOYEE.txt"(EMPLOYEE)]

    Job Server error (the Job Server may not be responding). The directory for the file cannot be validated to ensure that it is valid at design time. Ensure that the directory is valid by run-time.(BODI-1110017)

    It was expected. The job server was not configured.

    Did you see the icon ?

    Please remember that you have BODS server components installed on your machine and so you areresponsible to configure Job server as well.

    Launch Server manager

  • 8/11/2019 SAP BODS - Beginner

    35/46

    Click on Edit Job server config.

  • 8/11/2019 SAP BODS - Beginner

    36/46

    Click on Add and then OK.

  • 8/11/2019 SAP BODS - Beginner

    37/46

    Provide Job server name as per your wish.

    Click on Add.

  • 8/11/2019 SAP BODS - Beginner

    38/46

    In the Repository Information section, provide the local repository details.

    Click on Apply.

  • 8/11/2019 SAP BODS - Beginner

    39/46

    In the associated repositories, the repository name will be reflected.

    Click on OK.

  • 8/11/2019 SAP BODS - Beginner

    40/46

    You can now see the name of the Job server configured.

    Click on OK.

  • 8/11/2019 SAP BODS - Beginner

    41/46

    Click on Restart in the window

  • 8/11/2019 SAP BODS - Beginner

    42/46

    Click on OK to restart Data Services service.

    Close the designer.

    Re-launch the BODS Designer.

    Double-click the project where you have your job developed.

  • 8/11/2019 SAP BODS - Beginner

    43/46

    In the project area, right click on the job and select Execute.

  • 8/11/2019 SAP BODS - Beginner

    44/46

    You will see the Job server name listed that you configured earlier.

    Click on OK.

  • 8/11/2019 SAP BODS - Beginner

    45/46

    You find the job executed successfully!!!

    The good challenge is when job fails.

    Now, we see what records have been added.

    Go back to the dataflow.

    Click on the small view lens on each source and target.

    Source first:-

  • 8/11/2019 SAP BODS - Beginner

    46/46

    Target now:-

    So, we find that data is loaded from flat file to database table.

    http://www.saptechnical.com/Tutorials/BOBJ/bapi/Page2.htmhttp://www.saptechnical.com/Tutorials/BOBJ/bapi/Page2.htmhttp://www.saptechnical.com/Tutorials/BOBJ/bapi/Page2.htm

Recommended