Data Transfer from flat file to Database
Introduction:-
In this scenario i am demonstrating how to transfer the data from flat file to database in a step by step manner.
As data store is required to connect to any database we will start with creating the datastore for the database
Here we are using SQL server 2008 as a database.
1. Logon to the SAP Business Object Data Designer.
2. In Local Object Library click on Datastore Tab.
3. In Local Object Library click on Datastore Tab.
Window for creating new datastore will open as shown below.
Give all the details as shown below.
Here database name "RAHUL_MORE" that i am using is already created before creating the datastore.
4. Click "OK" & the Datastore will be created & can be seen in the Local Object Library as shown below.
Now we will create File Format to process the source file.
1. Click on the "Formats" tab in the Local Object Library in Data Service Designer.
2. Select "Flat Files", right click & click on "New". Flat File Editor will open as shown below.
We are using following file as the source.
3. Give all the details in the File Format Editor as follows.
When you select the File Name it will ask to overwrite the schema. I have selected "Yes" option in this option.
As a result of this you can see the altered schema on top of the RHS.
4. After giving all the details press "Save & Close". File Format will be created & can be seen in the Local Object Library.
Now after creating the Datastore & File Format we will design a job in the Data Service Designer.
2. Create a Batch Job.
3. Add a Dataflow into the job.
4.Build the scenario in the dataflow.
5. Mapping
Open the query & do mapping.
6.Insert Target Table.
We can either import the already created table or we can use template table which afterwards will actually be created in the database.
We are using template table here.
Template table can be seen in the dataflow.
7.Save & Validate the Job.
"Validate : No Errors Found (BODI 1220017)"
8.Execute the Job.
9.Check the output in the table.
After execution table will be created in the database & you can check the output.
For checking the output you can click on the Magnifying Glass icon of the table in the DS Designer.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
8 | |
5 | |
5 | |
4 | |
4 | |
4 | |
4 | |
3 | |
3 | |
3 |