Anda di halaman 1dari 32

AIM

CV.060 CONVERSION
TECHNICAL DESIGN
GM DC
Fixed Assets Conversion

Author: Subhas Samanta


Creation Date: February 25, 2011
Last Updated: February 27, 2011
Document Ref: GMDC CV040 Fixed Assets Conversion.doc
Version: 1.0
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Document Control

Change Record

23

Date Author Version Change Reference

25-Feb-11 Subhas Samanta 1.0 No Previous Document

Reviewers

Name Position

Distribution

Copy No. Name Location

1
Library Master Project Library
2 Project Manager
3
4

Note To Holders:

If you receive an electronic copy of this document and print it out, please write
your name on the equivalent of the cover page, for document control purposes.

Validation Program Logic:


Page 2 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

If you receive a hard copy of this document, please write your name on the front
cover, for document control purposes.

Validation Program Logic:


Page 3 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Contents

Document Control...................................................................................................................2

Introduction..............................................................................................................................4
Conversion Program........................................................................................................4
Century Date Compliance...............................................................................................4
Conversion Assumptions.......................................................................................................6

Setups and Prerequisites.........................................................................................................9

Scope..........................................................................................................................................9

Approach.................................................................................................................................10
Conversion Tables..........................................................................................................11
Ordering of Tables..........................................................................................................11
Dependencies..................................................................................................................11
Design Rules...........................................................................................................................12

Program Logic........................................................................................................................15

Upload Program Logic..........................................................................................................17

Translation Program Logic...................................................................................................18

Interface/Validation Program Logic..................................................................................18


Error Handling Program Logic....................................................................................22
Conversion Programs....................................................................................................22
Program Modules..................................................................................................................24
Value Sets.........................................................................................................................24
None..................................................................................................................................24
Executables......................................................................................................................24
Concurrent Programs.....................................................................................................26
Request Sets.....................................................................................................................29
Open and Closed Issues for this Deliverable....................................................................29
Open Issues......................................................................................................................29
Closed Issues...................................................................................................................29
Appendix A............................................................................................................................32

Validation Program Logic:


Page 4 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Validation Program Logic:


Page 5 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Introduction
This document defines the technical design and specifications required for the
fixed assets data conversion to convert assets from GMDCs Legacy systems to
the Oracle E-Business Suite.

Taconic will provide all the valid assets data in the form of extract files, which
will be input to Oracle fixed assets conversion program.

Fixed Assets conversion will load the assets data, validate the data and then
create them in Oracle Fixed Assets.

Conversion Program

This Conversion Program Technical Design defines the key assumptions, rules,
and logic that are needed to create the conversion programs. The conversion
program code is not included in this document. The Develop Conversion
Programs (CV.080) task contains the actual code that is written and debugged to
perform the conversion. The conversion design document is intended to provide
the developer with the necessary information for writing accurate conversion
programs.

The Conversion Program Technical Design is used to document and


communicate the conversion program design specifications for the conversion of
an individual business object to the Oracle Applications.

Distribute the Conversion Program Technical Design to:

Developers who are responsible for writing the various pieces of


conversion code
Conversion project staff
Client staff member responsible for signing off on the completeness
of this program design
Overall project manager
Conversion project manager

Use the following criteria to ensure the quality of this deliverable:

Is the conversion data mapping complete? Are there any application


setup decisions that have not been finalized which directly impact
the data mapping and the accuracy of the conversion code?
Are all of the rules, which impact conversion, documented so that
they can be written in the conversion code

Validation Program Logic:


Page 6 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Century Date Compliance

In the past, two-character date coding was an acceptable convention due to


perceived costs associated with the additional disk and memory storage
requirements of full four character date encoding. As the year 2000 approached,
it became evident that a full four character-coding scheme was more appropriate.

In the context of the Application Implementation Method (AIM), the convention


Century Date or C/Date support rather than Year2000 or Y2K support is used.
Coding for any future Century Date is now considered the modern business and
technical convention.

Every applications implementation team needs to consider the impact of the


century date on their implementation project. As part of the implementation
effort, all customizations, legacy data conversions, and custom interfaces need to
be reviewed for Century Date compliance.

Programmatically converted legacy data must be translated to the appropriate


century date state before being uploaded to the production tables. Manually
converted legacy data must be keyed into the data entry forms using 4 digits for
the year, where supported.

Validation Program Logic:


Page 7 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Conversion Assumptions

1. This document is prepared based on the approved functional design


document (CV040 version 1.1) and the scope of the solution is limited to the
features as mentioned explicitly in this document.

2. The fixed assets conversion program will be used for inserting the assets data
into base tables and not for updating the existing asset data.

3. The data file will be in the format specified in CV040 doc irrespective of the
data source.

4. There will be one pipe (|) delimited file for this conversion

5. All system level profile options have been setup.

6. Naming standards are as per build standards document.

7. All the required setups for this conversion will be completed before the
program is run.

8. GMDC custom Top ($XXGMDC_TOP) will be created in Unix server to


follow Capgemini OnDemand development standards.

9. No changes are done to the data files without prior notification to the
Caggemini technical team after they are transferred to the required directory
for upload.

10. The SQL*Loader will upload the records in the truncate mode, which means
all the previous records present in the staging table will be truncated, and the
staging table will be loaded with new records.

11. Bad, Discard and Log files are created in the $XXGMDC_TOP/bin directory.
Any file present in the $GMDC_TOP/bin with these names will be
overwritten with bad, log and discard file generated by the SQL*Loader.

12. All database objects like packages, procedure, functions, views, tables, etc
will be created in the XXGMDC schema.

13. The concurrent manager must be running in the applications before we can
run the Conversion program.

14. Assets will be sequentially renumbered in Oracle Assets.

15. Depreciation Method and Life of every asset will be coming from Asset
Category Setup.

16. Depreciation methods, lives, prorate of existing legacy assets will not be
changed during the conversion.

Validation Program Logic:


Page 8 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

17. The Asset Clearing Account will be providing by GMDC team. This is the
natural account for the Payables Code Combination. All other segments of
the combination will be derived from the asset Expense Account code
combination.

18. The Natural Account segment used by the seeded FA Account Generator
will be the assets cost account and depreciation reserve accounts based on
setup of the Asset Category. As part of standard functionality of Oracle
Assets, assets belonging to a particular Asset Category will be assigned the
default depreciation method and rate and life for that Category when posted
into Oracle Assets.

19. Extracted assets have been posted and reconciled to legacy General Ledger
balances. Detail and summary reports are available to support these
balances.

20. Each legacy asset will be converted with as one fixed asset unit (DEFAULT
VALUE = 1).

21. Asset currency code will default from the functional currency of the GL set
of book defined for the Asset book.

22. Asset tag numbers (if used) will be unique. Duplicate tag numberss record
will not load in the base table.

Validation Program Logic:


Page 9 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

23. Year to Date Depreciation (i.e. YTD_DEPRN; DEPR_YTD) cannot be greater


that the Life to Date Depreciation. In order to convert assets meeting this
criteria (where YTD depr greater than LTD depr), the YTD depr value will
need to be changed to Zero.

24. Cannot have LTD depr with zero cost. In the event of this error, the LTD
depreciation will be changed to be zero.

25. Assets in Oracle cannot be assigned to more than one category. The
conversion will process each category assignment as an individual asset.

26. Data cleansing will be performed by GMDC prior to submitting the data
extract.

Validation Program Logic:


Page 10 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Setups and Prerequisites


The following are the mandatory setups and prerequisites that need to be setup
before running this conversion program:

Set of Books (Chart of Accounts, COA segment values, Calendar, and


Currency) definitions will be completed.

Asset Books will be defined.

The instance has been set up to accommodate the Oldest Asset Date
placed in services for GMDC.

The mapping is key elements has been identified and set up specifically
depreciations methods; asset locations, asset key and asset categories.

The depreciation methods and prorate calendars will be defined.

The mapping of the depreciation expense accounts to the new Chart of


Account is complete.

Asset Numbering is set to automatic.

Scope
The following boundaries are specific to the conversion of the Fixed Assets
Conversion:

The scope of the conversion is to load data from the data files to the staging
tables, validate the data and then load the data into Interface tables.

The extract will contain the entire necessary Asset data elements required as
outlined in this design to successfully create an Asset in Oracle Assets.
Data cleansing will have been carried out on the source systems in time for the
conversion.
Where any derivation rules fail the validation step, the record will be erroring
out.

Required application setups must be completed before running the Coversion


Program.

Data Selection Criteria

Select all the records from Staging tables having PROCESS_FLAG = N,


PROCESS_FLAG = V, PROCESS_FLAG = L or PROCESS_FLAG = R.

XXTA_FA_MASS_ADDITIONS_STG

Validation Program Logic:


Page 11 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Data Manipulation Criteria

None

Data Production Criteria

None

Data Exclusion Criteria

None

Approach
The solution for this conversion requirement can be broken into two parts, the
loading of data into the temporary staging tables and the processing and
translation of that data before it is passed to interface to populate standard
Oracle base tables.

Data supplied in pipe delimited flat files (.cvs) and the format will be as defined
in the CV040.

The data files are loaded into the staging table using the host program that will
execute SQL LOADER. Once data file has been processed, any SQL Loader log
files, discard files, and bad files should be concatenated together and copied to
the appropriate directory and file where the user may review them. After each
run, the load program should accomplish any necessary cleanup.

The second step is the data validation program. This PL/SQL based program
should be able to select records from staging tables and process those records
before processing them using open interface. All incoming data file will be
written to a staging table by the load program. The validation program will select
these records and process them accordingly. The validation program will have
to maintain counts for total records processed, total records with errors, total
errors and total records with zero value. The program should also identify any
records with errors on the execution report.

The validation program should be run from within Oracle Applications. This
program will need an execution record, a defined concurrent program and be
attached to a request group.

Once the data in staging table is validated and valid data is inserted into
standard base table by using oracle oracle standard API.

Conversion Approach
Create one staging table.

XXTA_FA_MASS_ADDITIONS_STG

Validation Program Logic:


Page 12 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Asset data from the flat file will be inserted into the staging table using
the host program.
Once the staging table is populated the conversion package will perform
the necessary validations.
Validation is done for the records having process_flag equal to V as
VALIDATE or R as ERROR in the staging.
Records which are successfully processed will have the process_flag =
L as LOADED while error records will have the process_flag = R as
ERROR.
If any validation fails then the error is recorded in the error tables with
the appropriate error messages.
Every time the conversion program is run a summary report is created
that will tell the total count of records read, the number of records
processed and the number of records errored.
This process is continued until all the records are successfully processed
through standard API to create records in assets base tables.

Conversion Tables

The following tables are going to be populated in the Oracle application for the
conversion of Assets:

Table Name Sel Inser Upd Del


ect t ate ete

XXGMDC_FA_ADDITIONS_STG X X X X

XXGMDC_LOG_HEADERS X X

XXGMDC_LOG_LINES X X

FA_BOOK_CONTROLS X

FA_ADDITIONS_B X X

FA_CATEGORIES_B X

FA_ASSET_KEYWORDS X

FA_LOOKUPS_B X

FA_METHODS X

FA_FLAT_RATES X

FA_CONVENTION_TYPES X

Validation Program Logic:


Page 13 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

FA_LOCATIONS X

GL_CODE_COMBINATIONS X

Ordering of Tables

Below is the order in which the tables need to be populated for the conversion of
Assets

XXGMDC_FA_ADDITIONS_STG
XXGMDC_LOG_HEADERS
XXGMDC_LOG_LINES

Dependencies

Following is a list of tables that need to be populated before Fixed Asset


Conversion Program:

FA_CATEGORIES_B

FA_LOCATIONS

FA_ASSET_KEYWORDS

FA_BOOK_CONTROLS

FA_SYSTEM_CONTROLS

FA_METHODS

FA_CONVENTION_TYPES

FA_LOOKUPS_B

GL_CODE_COMBINATIONS

FA_FLAT_RATES

Foreign Key Dependencies

None

Validation Program Logic:


Page 14 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Parent/Child Dependencies

None

Quick Code Dependencies

None

Data Element Domains

None

Use of Sequence Generators

None

Design Rules
This section lists the processing rules, translation rules, derivation rules, foreign key rules that are
to be used in the conversion of assets:

Rule Description of the rule Rule implementation

Processing Rules

Validation Program Logic:


Page 15 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Program Logic

Download Program Logic

None.

Staging Table Creation Program Logic

This section describes the logic for the conversion table creation programs that
will be built to support the conversion of Assets.

Staging Table 1: XXTA_FA_MASS_ADDITIONS_STG

CREATE TABLE XXGMDC_FA_ADDITIONS_STG (

ASSET_ID NUMBER,

ASSET_NUMBER
VARCHAR2(15),

TAG_NUMBER
VARCHAR2(15),

SERIAL_NUMBER VARCHAR2 (35),

DESCRIPTION
VARCHAR2(80),

CATEGORIE_SEGMENT1 VARCHAR2(30),

CATEGORIE_SEGMENT2 VARCHAR2(30),

CATEGORIE_SEGMENT3 VARCHAR2(30)
DEFAULT 'FUT',

ATTRIBUTE_CATEGORY_CODE VARCHAR2(210),

ASSET_CATEGORY_ID NUMBER,

ASSET_KEY_SEGMENT1 VARCHAR2(30),

ASSET_KEY_SEGMENT2 VARCHAR2(30),

ASSET_KEY_SEGMENT3 VARCHAR2(30),

ASSET_KEY_SEGMENT4 VARCHAR2(30),

ASSET_KEY_CODE VARCHAR2(120),

Validation Program Logic:


Page 16 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

ASSET_KEY_CCID NUMBER (15),

CURRENT_UNITS NUMBER NOT NULL,

ASSET_TYPE VARCHAR2 (11) NOT NULL,

PARENT_ASSET_ID NUMBER (15),

MANUFACTURER_NAME VARCHAR2 (30),

MODEL_NUMBER VARCHAR2 (40),

PROPERTY_TYPE_CODE VARCHAR2 (10),

PROPERTY_1245_1250_CODE VARCHAR2 (4),

IN_USE_FLAG VARCHAR2 (3) NOT NULL,

INVENTORIAL VARCHAR2 (3) NOT NULL,

OWNED_LEASED VARCHAR2 (15) NOT NULL,

NEW_USED VARCHAR2 (4) NOT NULL,

UNIT_ADJUSTMENT_FLAG VARCHAR2 (3),

COMMITMENT VARCHAR2 (30),

INVESTMENT_LAW VARCHAR2 (30),

LEASE_NUMBER
VARCHAR2 (150),

LESSOR
VARCHAR2 (150),

WARRANTY_NUMBER
VARCHAR2 (150),

BOOK_TYPE_CODE VARCHAR2 (15)


NOT NULL,

AMORTIZE_ADJSUTMENTS VARCHAR2 (150),

ASSET_COMMENT VARCHAR2 (30),

DEPRECIATE_METHOD_CODE VARCHAR2 (12),

BASIC_RATE NUMBER
NOT NULL,

ASSETS_COST NUMBER,

Validation Program Logic:


Page 17 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

SALVAGE_VALUE NUMBER
DEFAULT 0,

SALVAGE_VALUE_TYPE VARCHAR2 (30),

SALVAGE_VALUE_TYPE_CODE VARCHAR2(3),

ORIGINAL_COST NUMBER
NOT NULL,

BEGINNING_NBV NUMBER,

YTD_DEPRN_COST NUMBER,

ACCUMULATED_COST NUMBER,

REVAL_RESERVE NUMBER,

REVAL_CEILING NUMBER,

DEPRECIATE_FLAG VARCHAR2 (3) NOT NULL,

DATE_PLACED_IN_SERVICE DATE
NOT NULL,

AMORTIZATION_START_DATE DATE,

SHORT_FISCAL_YEAR_FLAG DATE,

CONVERSION_DATE DATE,

ORIGINAL_DEPRN_START_DATE DATE,

PRORATE_CONVENTION_CODE VARCHAR2 (10),

LOCATION_CODE_COMB VARCHAR2 (120),

LOCATION_CCID NUMBER,

EXPENSE_ACC_CODE_COMB VARCHAR2 (240),

EXPENSE_ACC_CCID NUMBER,

DFF_CONTEXT VARCHAR2 (150) DEFAULT


'XXGMDC_ASSET_ADDITIONAL INFORM',

DFF_SEGMENT_MAKE VARCHAR2 (150),

DFF_SEGMENT_REG_NO VARCHAR2 (150),

DFF_SEGMENT_YEAR_MFG VARCHAR2 (150),

DFF_SEGMENT_ENG_NO VARCHAR2 (150),

Validation Program Logic:


Page 18 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

DFF_SEGMENT_CHASIS_NO VARCHAR2 (150),

DFF_SEGMENT_CUBIC_CAP VARCHAR2 (150),

DFF_SEGMENT_SUM_INSURED VARCHAR2 (150),

ATTRIBUTE1 VARCHAR2 (150),

ATTRIBUTE2 VARCHAR2 (150),

ATTRIBUTE3 VARCHAR2 (150),

ATTRIBUTE4 VARCHAR2 (150),

ATTRIBUTE5 VARCHAR2 (150),

ATTRIBUTE6 VARCHAR2 (150),

ATTRIBUTE7 VARCHAR2 (150),

ATTRIBUTE8 VARCHAR2 (150),

ATTRIBUTE9 VARCHAR2 (150),

ATTRIBUTE10 VARCHAR2 (150),

ATTRIBUTE11 NUMBER,

ATTRIBUTE12 NUMBER,

ATTRIBUTE13 NUMBER,

ATTRIBUTE14 NUMBER,

ATTRIBUTE15 NUMBER,

ATTRIBUTE16 NUMBER,

CREATED_BY NUMBER,

CREATION_DATE DATE ,

LAST_UPDATED_BY NUMBER,

LAST_UPDATE_DATE DATE,

LAST_UPDATE_LOGIN NUMBER,

REQUEST_ID NUMBER,

PROCESSING_ROW_ID NUMBER,

PROCESSING_STATUS VARCHAR2(1) DEFAULT


'N',

Validation Program Logic:


Page 19 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

PROCESSING_MESSAGE VARCHAR2(360)

Validation Program Logic:


Page 20 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Upload Program Logic


This section describes the logic for the conversion upload programs that will be built to support
the conversion of Assets.
1. There is a host concurrent program which takes data file path with its names (assets.csv) as
parameters and calls the SQL*Loader utility to load the data from the delimited file into the
staging tables. The Staging tables are as follows:
XXGMDC_FA_ADDITIONS_STG

The following is the control file (CTL) script, which will upload the data from the flat file to
the staging table (XXTA_FA_MASS_ADDITIONS_STG):
LOAD DATA
TRUNCATE
INTO TABLE XXGMDC_FA_ADDITIONS_STG
FIELDS TERMINATED BY '|' OPTIONALLY ENCLOSED BY '"'
TRAILING NULLCOLS
(
TAG_NUMBER CHAR
"TRIM (:TAG_NUMBER)"
, DESCRIPTION
CHAR "TRIM (:DESCRIPTION)"
, CATEGORIE_SEGMENT1
CHAR "TRIM (:CATEGORIE_SEGMENT1)"
, CATEGORIE_SEGMENT2
CHAR "TRIM (:CATEGORIE_SEGMENT2)"
, CATEGORIE_SEGMENT3
CHAR "TRIM (:CATEGORIE_SEGMENT3)"
, DFF_SEGMENT_MAKE
CHAR "TRIM (:DFF_SEGMENT_MAKE)"
, DFF_SEGMENT_REG_NO
CHAR "TRIM (:DFF_SEGMENT_REG_NO)"
, DFF_SEGMENT_YEAR_MFG
CHAR "TRIM (:DFF_SEGMENT_YEAR_MFG)"
, DFF_SEGMENT_ENG_NO
CHAR "TRIM (:DFF_SEGMENT_ENG_NO)"
, DFF_SEGMENT_CHASIS_NO
CHAR "TRIM (:DFF_SEGMENT_CHASIS_NO)"
, DFF_SEGMENT_CUBIC_CAP
CHAR "TRIM (:DFF_SEGMENT_CUBIC_CAP)"
, DFF_SEGMENT_SUM_INSURED
CHAR "TRIM (:DFF_SEGMENT_SUM_INSURED)"
, ASSET_KEY_CODE
CHAR "TRIM (:ASSET_KEY_CODE)"
, ASSET_TYPE
CHAR "TRIM (:ASSET_TYPE)"
, MANUFACTURER_NAME
CHAR "TRIM (:MANUFACTURER_NAME)"
, IN_USE_FLAG
CHAR "TRIM (:IN_USE_FLAG)"
, INVENTORIAL
CHAR "TRIM (:INVENTORIAL)"

Validation Program Logic:


Page 21 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

, PROPERTY_TYPE_CODE
CHAR "TRIM (:PROPERTY_TYPE_CODE)"
, OWNED_LEASED
CHAR "TRIM (:OWNED_LEASED)"
, NEW_USED
CHAR "TRIM (:NEW_USED)"
, BOOK_TYPE_CODE
CHAR "TRIM (:BOOK_TYPE_CODE)"
, ORIGINAL_COST
CHAR "TRIM (:ORIGINAL_COST)"
, ACCUMULATED_COST
CHAR "TRIM (:ACCUMULATED_COST)"
, SALVAGE_VALUE_TYPE
CHAR "TRIM (:SALVAGE_VALUE_TYPE)"
, DATE_PLACED_IN_SERVICE
CHAR "TRIM (:DATE_PLACED_IN_SERVICE)"
, DEPRECIATE_METHOD_CODE
CHAR "TRIM (:DEPRECIATE_METHOD_CODE)"
, BASIC_RATE
CHAR "TRIM (:BASIC_RATE)"
, PRORATE_CONVENTION_CODE
CHAR "TRIM (:PRORATE_CONVENTION_CODE)"
, CURRENT_UNITS
CHAR "TRIM (:CURRENT_UNITS)"
, EXPENSE_ACC_CODE_COMB
CHAR "TRIM (:EXPENSE_ACC_CODE_COMB)"
, LOCATION_CODE_COMB
CHAR "TRIM (:LOCATION_CODE_COMB)"
, DEPRECIATE_FLAG
CONSTANT 'YES'
, PROCESSING_STATUS
CONSTANT 'N'
, created_by
"FND_GLOBAL.USER_ID"
, creation_date
"SYSDATE"
, last_updated_by
"FND_GLOBAL.USER_ID"
, last_update_date "SYSDATE"
)

2. Validation of data is done in the staging table. The Staging table is as follows:
XXGMDC_FA_ADDITIONS_STG
3.If a record fails during data validation then errors are inserted into the error table
(XXGMDC_LOG_HEADERS & XXGMDC_LOG_LINES) and for the errored out record the
process_flag column in the staging tables will be updated to R. Error reporting will take care of
incorrect dates format, missing mandatory fields etc.
4. After validations are complete, the procedure is called to load the valid data into Oracle base
table for record that has been successfully validated without any errors. Oracle standard open
API will be used to create records in Oracle base tables.

Validation Program Logic:


Page 22 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

5. All the loaded data in staging tables will be marked as LOADED (process_flag = L) in the
staging tables. Records with process_flag=R will not be processed in the stanging tables.

Translation Program Logic


This section describes the logic for the conversion translation programs that will
be built to support the conversion of Assets.

N/A

Validation Program Logic


This section describes the logic for the conversion interface/validation programs that will be built
to support the conversion of Assets.

Describes the program logic for the interface/validation program(s) used to convert the business
object.

The conversion of Assets is initiated through a main program, which will in turn call rest of the
programs depend on success.

XXGMDC FA Asset Number Conversion Program

XXGMDC FA Asset Number Conversion Program is the wrapper program, which will
call the XXGMDC_FA_ADDITIONS_PKG.MAIN pl/sql program.

Following are the various sub-procedures under XXGMDC FA Asset Number


Conversion Program concurrent program:
MAIN
This is the main procedure that starts the conversion processing. This procedure in
turns calls other programs to load data into staging tables, validate staging table
records and process them using API.
WRITE_LOG
This procedure is used for capturing logs.
INSERT_ERROR
This procedure is used for inserting errors to XXGMDC_LOG_LINES table.
READ_RECORDS

Validation Program Logic:


Page 23 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

This procedure reads records from the staging table and assigns the request_id
and processing_row_id value to the staging table.
SUBMIT_CHILD
This procedure divides the records by their batch sizes and calls the prodedure.
This procedure calls the fa_number_main procedure.
REPORT_RESULTS
This procedure displays the record statistics from staging table.

Pseudo-code for the XXGMDC_FA_ADDITIONS_PRG :

MAIN

1. If data file parameter is given, call load program XXGMDC FA Asset Number -
Load Data, otherwise go to next step.

2. Initialize the Error Handlers to capture the run-time errors.

3. Call validate program by submmiting XXGMDC FA Asset Number Conversion


Program

VALIDATE_FA_NUMBER_RECORDS
Declare
Declare all local variables

CURSOR cur_get_stg_data IS
SELECT * FROM XXGMDC_FA_ADDITIONS_STG
WHERE process_flag in (parameter value);

BEGIN
Initialize the error flag.

Loop for cursor cur_get_stg_data.


Perform validation rules.

IF any validation fails, generate error and update the record as R. Go to


next record.
Go to next record in Loop for cursor cur_get_stg_data.
END

CREATE_FA_NUMBER

This procedure will insert valid records into base table by oracle standard API.

Declare all local variables


CURSOR c_asset IS
SELECT * FROM XXGMDC_FA_ADDITIONS_STG
WHERE process_flag = V;

Validation Program Logic:


Page 24 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Ln_record_count := 0;

Loop for cursor c_asset

Ln_record_count := ln_record_count + 1;

For each asset record, call API with values from necessary c_asset columns.
END LOOP

End Loop

Error Handling Program Logic

This section describes the logic for the error handling procedure that will be built
to support the conversion of assets.

The following are the procedures that will be used in handling of errors.

INSERT_ERROR procedure is used to insert all the error messages in to the log
table.

XXGMDC_COMMON_UTIL_PKG.PRINT_EAM_OUTPUT procedure is to print


the records in the log file, based on the request id.

In case of any setup validation error, assign retcode: = 2. This is done so that the
program completes in error.

The data in the staging table are not deleted so that error records can be
identified if required. The SQL*Loader will delete data from the staging table
before loading data to prevent storing of duplicate data in staging table.

Note: The program should complete all data & apps setup related validations (mentioned in
validation section) before giving a consolidated error report. Program should list all data/setup
errors before stopping rather than stopping when first validation /setup error occurs. In case of
system errors, program should give the error message and stop execution (ret code=2).

Conversion Programs

The following table lists each program created for the conversion of Assets:

Validation Program Logic:


Page 25 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets
Conversion.doc

Program Type Program Name Description/Purpose Program Develope Flat File:/File Name and Location (if any)
Location r

Concurrent XXGMDC FA Asset XXGMDC_FA_ADDITIONS_PKG.MAIN


Program Number Conversion
Program
Concurrent XXGMDC FA Asset A Host program is used $XXGMDC_TO XXGMDC_FA_ADDITIONS_PRG
Program Number - Load Data
to upload the asset data P/bin
from the extract file to
the Staging Table.
(assets.csv)
Control Files To load the data in XXGMDC_FA_ADDITIONS_CTL.ctl
staging tables
Package XXGMDC_FA_ADDITI All plsql operations for XXGMDC_FA_ADDITIONS_PKG
ONS_PKG asset conversion

Validation Program Logic:


Page 26 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets Conversion.doc

Program Modules

Common Routine

This program uses the following common routines:

Common Code Package (XXGMDC_COMMON_UTIL_PKG)

Value Sets

None

Executables

Executable Name XXGMDC_FA_ASSET_NUMBER_CNV

Short Name XXGMDC_FA_ASSET_NUMBER_CNV

Application XXGMDC

Description XXGMDC FA Asset Number Conversion Program

Execution Method PL/SQL Stored Procedure

Execution File Name XXGMDC_FA_ADDITIONS_PKG.MAIN

Subroutine Name

Executable Name XXGMDC_FA_ASSET_NUMBER_LOAD


Validation
Program Logic: Page 27 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets Conversion.doc

Short Name XXGMDC_FA_ASSET_NUMBER_LOAD

Application XXGMDC

Description XXGMDC FA Asset Number - Load Data

Execution Method Host

Execution File Name XXGMDC_FA_ADDITIONS_PRG

Subroutine Name

Concurrent Programs

Program XXGMDC FA Asset Number Conversion Program

Short Name XXGMDC_FA_ASSET_NUMBER_CNV

Application XXGMDC

Description XXGMDC FA Asset Number Conversion Program

Execution Name XXGMDC_FA_ASSET_NUMBER_CNV

Priority

Request Type

Style

Parameters:
Validation
Program Logic: Page 28 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets Conversion.doc

Se Parameter Description Enabl Value Set Re Enab Dis Disp Prom To


q ed q le p. . pt ken
Sec. Size
10 p_batch_si Number of records per Y 15 Number Y N Batch
ze batch for multi- Size
threaded processing
20 p_validate Perform record Y Yes_No Y Valid
_only validations only No ate
actual data loads Only
30 p_debug_l Y XXGMDC_ Y Debu
Defines the amount of
evel CONV_DEB g
detail found in the log.
UG_LEVEL Level
Valid values are 0-4
40 p_candida Y XXGMDC_ Y Candi
N)ew
te_set CONV_CA date
NDIDATE_ Set
R)ejected
SET
V)alidated

A)ll
50 p_test_rec Y 15 Digit Y Test
Process eligible
ords Number Recor
candidate rows
ds

Program XXGMDC FA Asset Number - Load Data

Short Name XXGMDC_FA_ASSET_NUMBER_LOAD

Application XXGMDC

Description XXGMDC FA Asset Number - Load Data

Execution Name XXGMDC_FA_ASSET_NUMBER_LOAD

Priority

Validation
Program Logic: Page 29 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets Conversion.doc

Request Type

Style

Parameters:
Se Parameter Description Enabl Value Set Re Enab Dis Disp Prom To
q ed q le p. . pt ken
Sec. Size
10 P_FILE_P Data file Y 120 Characters Y N Data
ATH_NA name with file
ME path name
with
path

Request Sets

None

Open and Closed Issues for this Deliverable

Open Issues

Validation
Program Logic: Page 30 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets Conversion.doc

ID Issue Resolution Responsibility Target Date Impact Date

Closed Issues

ID Issue Resolution Responsibility Target Date Impact Date

Validation
Program Logic: Page 31 of 32
CV.060 Doc Ref GMDC CV040 Fixed Assets Conversion.doc

Validation
Program Logic: Page 32 of 32

Anda mungkin juga menyukai