Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Prepared By
Mohammed Rizk Ibrahim Oracle Technical Consultant
Main Topics
- Part I
1. What's data migration? 2. Most common Tools used for data uploading 3. APIs used 4. Testing the API script : Uploading One supplier 5. Validating of supplier data after uploading 6. Creating custom Objects a) Custom Table b) Custom Package c) Custom Concurrent Program 7. Importing suppliers data into custom table 8. Filtering Data to avoid the duplicate suppliers
Main Topics
- Part II
1. Whats concurrent program 2. Types of concurrent program 3. Creating concurrent program 4. Uploading data process 5. Exercises on uploading the suppliers
Main Topics
Part I
4
system to another ,data migration is necessary when an organization decides to use a new system to use any data that was used in the old system
Data Migration phases 1. Data should be collected by MOF Technical Team 2. TRANSFER(MAP) : transfer or map data from the old format to the new format 3. LOAD : upload the mapped data to the new system and test it to check if it is fully functional . 4. Oracle Base Tables AP_SUPPLIERS,AP_SUPPLIER_SITES_ALL and PER_ALL_PEOPLE_F.
5
Interface Table
Its a tool used by functional consultants through importing data excel sheets into interface tables .after that through oracle application you can run a program that is responsible for transferring data from the interface tables to oracle base table.
API
Application Program Interfaces are standard stored procedure packages or functions created for performing specific activities in the Oracle Apps EBusiness Suite. One of these activities is inserting the data into the a certain table ( like supplier or customer tables ) while insuring the integrity of the application .
Our Action Plan : 1. EXTRACT : define Format of the extracted files , whats the file format that will be extracted from PACI system : Excel, Textetc? Creation of a custom table (A temp table for suppliers mapping data provided by PACI ) Addition of constraints ,Checking for UNIQUE columns and NOT NULL columns like original tables for customers and suppliers in oracle apps.
2. 3.
Data Migration phases 4. Running Loading utility & Creation of LOG file ,Load these data from temp table by using TOAD tool after which a log file is created, the log file will contain data about the uninserted row . Verify Data, Review invalid rows and fix it, use TOAD to re import the rows again
5.
APIS used
The Following APIs are used to upload supplier data :
o o API Header POS_VENDOR_PUB_PKG.CREATE_VENDOR ( parameters ) API Sites POS_VENDOR_PUB_PKG.CREATE_VENDOR_SITE( parameters )
10
11
12
DECLARE l_vendor_site_rec ap_vendor_pub_pkg.r_vendor_site_rec_type; l_return_status VARCHAR2(10); l_msg_count NUMBER; l_msg_data VARCHAR2(1000); l_vendor_site_id NUMBER; l_party_site_id NUMBER; l_location_id NUMBER; BEGIN -- Required l_vendor_site_rec.vendor_id :=57023 l_vendor_site_rec.vendor_site_code := 'MOF'; l_vendor_site_rec.address_line1 := '; l_vendor_site_rec.country := 'KW'; l_vendor_site_rec.org_id := 85; -- Optional l_vendor_site_rec.purchasing_site_flag:='Y'; l_vendor_site_rec.pay_site_flag :='Y'; l_vendor_site_rec.rfq_only_site_flag :='N'; l_vendor_site_rec.phone := '67615006'; pos_vendor_pub_pkg.create_vendor_site( p_vendor_site_rec => l_vendor_site_rec, x_return_status => l_return_status,
13
x_msg_count
=> l_msg_count, x_msg_data => l_msg_data, x_vendor_site_id => l_vendor_site_id, x_party_site_id => l_party_site_id, x_location_id => l_location_id);
COMMIT; dbms_output.put_line('return_status: '||l_return_status); dbms_output.put_line('msg_data: '||l_msg_data); dbms_output.put_line('vendor_site_id: '||l_vendor_site_id); dbms_output.put_line('party_site_id: '||l_party_site_id); dbms_output.put_line('location_id: '||l_location_id); END;
14
15
16
17
18
We can import the data supplier into custom table as the following:
Fill in an excel sheet with the data supplier. Column name of excel sheet have to be the same column name of table data base .
19
20
21
The next screen will appear ,then we select Excel File (*.xls) and press Next button
22
23
24
As we shown in figure we start first row from 2 and we didn't mention number for last row which means we want to get all data in excel file then Next
25
As shown in figure we've retrieve data but we have to make sure that the column name of source (excel table) match the column name in destination (oracle table) type by using AutoMap the Next
26
This figure shows us the mapping of field in source and destination then Next
27
28
Here TOAD raises error message to show duplicate data for supplier.
29
After process import data to custom table finished will show summary for this process as the following
30
We can display data that we already imported from excel file after we complete the import data process (load) by press on Show Data after we check the data we should commit data by press on red arrow button
Commit Icon
31
Main Topics
- Part II
1. Whats concurrent program 2. Types of concurrent program 3. Creating concurrent program 4. Uploading data process 5. Exercises on uploading the suppliers
32
concurrent program
Concurrent program is an executable file that runs simultaneously with other concurrent programs and with online operations. Typically, a concurrent program is a long-running, data-intensive task, such as posting a journal or generating a report. Types of concurrent program 1. A SQL script 2. A SQL * Loader program 3. Java program 4. Oracle Report 5. Pl/SQL program ( or call it a stored procedure/package procedure)
33
34
35
Request Group
How can access and run this concurrent program ? to run this concurrent program have to assign it to specific request group. Whats Request Group ? Request Group is the collection of requests, request sets, and concurrent programs that a user, operating under a given responsibility, can select from the Submit Requests window
36
37
38
The same scenario will repeat for uploading the employees and define them as suppliers but will use different Custom concurrent Programs as the following : 1. Upload Employees 2. Update Employees Assignment 3. Define the Suppliers as Employees
39
Upload Employees
40
41
42
Notes
Kindly note that every time after loading data from excel to custom table by TOAD have to update flag is called ACTIVE_ROW=Y.
43