Document Control
Change Record
5
Date 27-Feb2012
Versio n 1.0
Reviewers
Position Manager
Distribution
Copy No. 1 2 3 4
Name
Location
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. If you receive a hard copy of this document, please write your name on the front cover, for document control purposes.
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Contents
Document Control.......................................................................................ii Technical Overview.....................................................................................v Approach...............................................................................................v Module List............................................................................................v <Form Title> - Form Logic.........................................................................vi Navigation Logic...................................................................................vi Block Relationship Diagram.................................................................vi Table and View Usage.........................................................................vii Zone and Field Summary...................................................................viii XXFLS - Order Acknowledgement Report Boise - Concurrent Program Logic ...................................................................................................................ix Calling Arguments................................................................................ix Table and View Usage........................................................................xiii Program Logic (pseudo code)..............................................................xv SQL Statements...................................................................................xv Default Data Sources..........................................................................xix Validation Logic..................................................................................xix Incompatibility.....................................................................................xx Performance Considerations...............................................................xx Other Considerations...........................................................................xx Integration Issues.....................................................................................xxi Changes Required..............................................................................xxi Shared Components...........................................................................xxi Alert conditions...................................................................................xxi Incompatibilities.................................................................................xxi Performance Issues............................................................................xxi Database Design.....................................................................................xxii Desired Table Changes......................................................................xxii New/Updated Seed Data....................................................................xxii Descriptive Flexfields.........................................................................xxii Value Sets..........................................................................................xxii Grants/Synonyms.............................................................................xxiii Archiving...........................................................................................xxiii Database Diagram...........................................................................xxiii Tables, Indexes, Sequences..............................................................xxiii Installation Requirements......................................................................xxiv Implementation Notes.............................................................................xxv Design Summary...............................................................................xxv
XXFLS - Order Acknowledgement Report Boise - Concurrent Program Logic 13 of 24
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Coding Summary...............................................................................xxv Testing Summary..............................................................................xxv Installation........................................................................................xxvi Open and Closed Issues for this Deliverable..........................................xxvii Open Issues......................................................................................xxvii Closed Issues...................................................................................xxvii
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Technical Overview
This document defines the technical components required to implement customization Order Acknowledgement Report. This Application Extension Technical Design document complements the Application Extension Functional Design document for Order Acknowledgement Report and you should consider the set to be the complete detailed design.
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Navigation Logic
Entry Mode START 1. User enters data into form. 2. User commits transaction. 3. Form calls concurrent program X with selected parameters. 4. Form displays "Request xxxx has been sent to the concurrent manager". 5. User presses any key to acknowledge message. 6. Form clears. 7. Cursor moves to field 1. END
B a s e T a b le L o o k u p T a b le
P a re n t of C h ild of
C h i ld T a b l e
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Insert
Update
Delete
Base Table
hr_all_organization_units hr_locations_all hr_operating_units xle_entity_profiles per_all_people_f fnd_attachment_functions fnd_doc_category_usages fnd_documents_vl fnd_attached_documents fnd_documents_short_text oe_order_headers_all oe_order_lines_all oe_order_types_v oe_transaction_types_tl oe_arguments_v oe_lookups oe_charge_lines_v ar_lookups ra_terms ra_contacts hz_parties hz_party_sites hz_loc_assignments hz_locations hz_cust_acct_sites_all hz_cust_accounts_all hz_cust_accounts hz_relationships ra_salesreps fnd_user mtl_system_items mtl_system_items_tl mtl_units_of_measure wsh_carriers_v wsh_carrier_ship_methods _v fnd_territories_vl
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Oranization_na me Sales Person Customer RFQ Terms Ship Via Order Date Item Quantity Part # Item Description Unit Weight Unit Price Extended Price Zone 2 Base Table: Where/Order By:
Field Field 1 COLUMN_NAME Type Char Rqd ? No
Yes
Default
Validation
(
QuickPick Display MEANING from <Application Short Name>_LOOKUPS where LOOKUP_TYPE = '<lookup type>
(QuickPick validation)
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Calling Arguments
XXFLS- Order Acknowledgement Report Boise is called from the Standard Report Submission form with the following arguments: Argument Set of Books Id Prompt Set of Books Id Value Set OE: Number Zero Precision Default Value select to_number(FND_PRO FILE.VALUE('GL_SET_ OF_BKS_ID')) from dual select fnd_profile.value('OR G_ID') from DUAL OE_ID_FLEX_CODE select meaning from oe_lookups where lookup_type = 'ITEM_DISPLAY_CODE ' and lookup_code = 'D'
Booked Status Order Type Order Number (From) Order Number (To) Order Date (From) Order Date (To)
Booked Status Order Type Order Number (From) Order Number ( To) Order Date ( From) Order Date (To)
OM: Yes or No ONT_SRS_ORDER_T YPE FND_NUMBER FND_NUMBER FND_STANDARD_DA TE FND_STANDARD_DA TE select : $FLEX$.FND_NUMBER from sys.dual select fnd_date.date_to_cha rdate(fnd_date.canon ical_to_date(: $FLEX$.FND_STANDA RD_DATE)) from sys.dual
XXFLS_ONT_SRS_CU STOMER_NAME
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Argument Bill To Customer Name (To) Ship To Customer Name (From) Ship To Customer Name (To) Schedule Date (From) Schedule Date (To)
Prompt Invoice To Customer Name (To) Ship To Customer Name ( From) Ship To Customer Name (To) Schedule Date (From) Schedule Date (To)
Value Set XXFLS_ONT_SRS_CU STOMER_NAME XXFLS_ONT_SRS_CU STOMER_NAME XXFLS_ONT_SRS_CU STOMER_NAME FND_STANDARD_DA TE FND_STANDARD_DA TE
select : $FLEX$.XXFLS_ONT_S RS_CUSTOMER_NAME from sys.dual select fnd_date.date_to_cha rdate(fnd_date.canon ical_to_date(: $FLEX$.FND_STANDA RD_DATE)) from sys.dual select fnd_date.date_to_cha rdate(fnd_date.canon ical_to_date(: $FLEX$.FND_STANDA RD_DATE)) from sys.dual select fnd_date.date_to_cha rdate(fnd_date.canon ical_to_date(: $FLEX$.FND_STANDA RD_DATE)) from sys.dual select meaning from oe_lookups where lookup_type='REPOR T_ORDER_CATEGORY ' and lookup_code='SALES' select meaning from oe_lookups where lookup_type='REPOR T_LINE_DISPLAY' and lookup_code='ALL'
FND_STANDARD_DA TE FND_STANDARD_DA TE
FND_STANDARD_DA TE FND_STANDARD_DA TE
Order Category
Order Category
ONT_SRS_ORDER_C ATEGORY
Line Category
Line Category
ONT_SRS_LINE_CAT EGORY
Salesperson Created By
Salesperson Created By
ONT_SRS_SALESREP S ONT_SRS_AOL_USER
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Default Value select meaning from fnd_lookups where lookup_type='YES_N O' and lookup_code='Y'
Deliver To Customer (From) Deliver To Customer (To) Show Header Attachments Show Body Attachments
Deliver To Customer Name(From) Deliver To Customer Name (To) Show Header Attachments
XXFLS_ONT_SRS_CU STOMER_NAME XXFLS_ONT_SRS_CU STOMER_NAME OM: Yes or No select : $FLEX$.XXFLS_ONT_S RS_CUSTOMER_NAME from sys.dual select meaning from fnd_lookups where lookup_type = 'YES_NO' and lookup_code = 'N' select meaning from fnd_lookups where lookup_type = 'YES_NO' and lookup_code = 'N' select meaning from fnd_lookups where lookup_type = 'YES_NO' and lookup_code = 'N' MFG_ORGANIZATION _ID select meaning from fnd_lookups where lookup_type='YES_N O' and lookup_code='N' select meaning from fnd_lookups where lookup_type='YES_N O' and lookup_code='N'
OM: Yes or No
OM: Yes or No
OM: Yes or No
Main Template:-
XXFLS_ONT_OEXOE ACK_BOISE.rtf
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Insert
Update
Delete
hr_all_organization_units
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Insert
Update
Delete
hr_locations_all hr_operating_units xle_entity_profiles per_all_people_f fnd_attachment_functions fnd_doc_category_usages fnd_documents_vl fnd_attached_documents fnd_documents_short_text oe_order_headers_all oe_order_lines_all oe_order_types_v oe_transaction_types_tl oe_arguments_v oe_lookups oe_charge_lines_v ar_lookups ra_terms ra_contacts hz_parties hz_party_sites hz_loc_assignments hz_locations hz_cust_acct_sites_all hz_cust_accounts_all hz_cust_accounts hz_relationships ra_salesreps fnd_user mtl_system_items
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
SQL Statements
1 - Data Selection Query 1 for Ligal Entity --------------------------SELECT haou.organization_id, haou.name org_name, RTRIM (xle.name, '(LE)') legal_entity_name, hl.derived_locale, hl.location_code, hl.address_line_1, hl.address_line_2, hl.address_line_3, hl.town_or_city, hl.country, hl.postal_code, hl.region_1, hl.region_2, hl.telephone_number_1 tel, hl.telephone_number_2 fax FROM hr_all_organization_units haou, hr_locations_all hl, hr_operating_units hou, xle_entity_profiles xle WHERE haou.location_id = hl.location_id AND hou.organization_id = haou.organization_id AND hou.default_legal_context_id = legal_entity_id Query 2 for Headers ----------------------
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Query 4 for Discount ---------------------P.HEADER_ID, P.LINE_ID, SUM(DECODE ( P.LINE_ID, NULL, DECODE (P.CREDIT_OR_CHARGE_FLAG, 'C', (-1) * P.OPERAND, P.OPERAND), DECODE ( P.CREDIT_OR_CHARGE_FLAG, 'C', DECODE ( P.ARITHMETIC_OPERATOR, 'LUMPSUM', DECODE (l.ordered_quantity, 0, 0, (-1) * (P.OPERAND)), (-1) * (L.ORDERED_QUANTITY * P.ADJUSTED_AMOUNT) ), DECODE (P.ARITHMETIC_OPERATOR, 'LUMPSUM', DECODE (l.ordered_quantity, 0, 0, P.OPERAND), (L.ORDERED_QUANTITY * P.ADJUSTED_AMOUNT)) ) )) DISCOUNT FROM OE_PRICE_ADJUSTMENTS P, --OE_PRICE_ADJUSTMENTS P, OE_ORDER_LINES_ALL L WHERE P.LINE_ID = L.LINE_ID(+) AND P.LIST_LINE_TYPE_CODE = 'DIS' AND P.APPLIED_FLAG = 'Y' --AND P.ADJUSTMENT_NAME not in('Price Override') AND P.LIST_HEADER_ID IN (SELECT LIST_HEADER_ID FROM QP_LIST_HEADERS_TL WHERE NAME <> 'Price Override') --<>7014 --AND P.HEADER_ID=1789 GROUP BY P.HEADER_ID, P.LINE_ID Query 5 Header Attachments ----------------------------SELECT DECODE (fndcatusg.format, 'H', st.short_text, NULL, st.short_text, NULL) hdr_short_text, DECODE (fndcatusg.format, 'B', st.short_text, NULL) body_short_text, DECODE (fndcatusg.format, 'F', st.short_text, NULL) ftr_short_text, DECODE (fndcatusg.format, 'H', description, NULL) hdr_attach_desc, DECODE (fndcatusg.format, 'B', description, NULL) body_attach_desc, DECODE (fndcatusg.format, 'F', description, NULL) ftr_attach_desc, ld.LONG_TEXT, fnddoc.CATEGORY_DESCRIPTION, pk1_value hdr_attach_pk, fnddoc.datatype_name hdr_attach_dtype
XXFLS - Order Acknowledgement Report Boise - Concurrent Program Logic 13 of 24
SELECT
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
fnd_attachment_functions fndattfn, fnd_doc_category_usages fndcatusg, fnd_documents_vl fnddoc, fnd_attached_documents fndattdoc, fnd_documents_short_text st, fnd_documents_long_text ld WHERE fndattfn.attachment_function_id = fndcatusg.attachment_function_id AND fndcatusg.category_id = fnddoc.category_id AND fnddoc.document_id = fndattdoc.document_id AND fndattfn.function_name = 'OEXOEACK' AND fndattdoc.entity_name = 'OE_ORDER_HEADERS' AND fnddoc.media_id = st.media_id AND fnddoc.media_id = ld.media_id --and pk1_value=1750 ORDER BY fndattdoc.seq_num Query 5.1 Header Attachments ----------------------------SELECT fndattdoc.pk1_value, log_att.LONG_TEXT ATTH_SALUTATION, fnddoc.CATEGORY_DESCRIPTION FROM fnd_documents_long_text log_att, fnd_documents_vl fnddoc, fnd_attached_documents fndattdoc, fnd_attachment_functions fndattfn WHERE fnddoc.media_id = log_att.media_id AND fnddoc.document_id = fndattdoc.document_id AND fndattfn.function_name = 'OEXOEACK' AND fndattdoc.entity_name = 'OE_ORDER_HEADERS' --and fndattdoc.pk1_value=1750 --and fnddoc.category_id=1000653 AND fnddoc.CATEGORY_DESCRIPTION IN ('FLS SPARES SALUTATION') Query 5.2 Header Attachments ----------------------------SELECT fndattdoc.pk1_value, log_att.LONG_TEXT ATTH_FOOTER, fnddoc.CATEGORY_DESCRIPTION FROM fnd_documents_long_text log_att, fnd_documents_vl fnddoc, fnd_attached_documents fndattdoc, fnd_attachment_functions fndattfn WHERE fnddoc.media_id = log_att.media_id AND fnddoc.document_id = fndattdoc.document_id AND fndattfn.function_name = 'OEXOEACK' AND fndattdoc.entity_name = 'OE_ORDER_HEADERS' --and fndattdoc.pk1_value=1750 --and fnddoc.category_id=1000653 AND fnddoc.CATEGORY_DESCRIPTION = 'FLS SPARES FOOTER' Query 6 line Attachments -------------------------SELECT st.short_text, description line_attach_desc, pk1_value line_attach_pk, datatype_name line_attach_dtype, fndcatusg.format line_attach_format FROM fnd_attachment_functions fndattfn, fnd_doc_category_usages fndcatusg, fnd_documents_vl fnddoc, fnd_attached_documents fndattdoc, fnd_documents_short_text st WHERE fndattfn.attachment_function_id = fndcatusg.attachment_function_id AND fndcatusg.category_id = fnddoc.category_id
XXFLS - Order Acknowledgement Report Boise - Concurrent Program Logic 13 of 24
FROM
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
ORDER BY
AND fnddoc.document_id = fndattdoc.document_id AND fndattfn.function_name = 'OEXOEACK' AND fndattdoc.entity_name = 'OE_ORDER_LINES' AND fnddoc.media_id = st.media_id fndattdoc.seq_num Query 7 Sum of Products Cost group by FOB --------------------------------------------
SELECT
FROM
WHERE
GROUP BY
ORDER BY
l.header_id, --l.pricing_quantity, --uom.UOM_CODE, --l.unit_selling_price Selling_Price, SUM ( (l.unit_selling_price) * (l.ordered_quantity)) SUM_total_price, lk2.meaning Line_FOB, lk2.description Line_fob_des oe_order_lines_all l, oe_line_types_v ol, mtl_units_of_measure uom, mtl_system_items si, wsh_carriers_v f, WSH_CARRIER_SHIP_METHODS_V CSM, /* Added for bug#2373742 */ --oe_agreements_v a, oe_lookups lk1, ar_lookups lk2, ra_salesreps sr, ra_terms terms l.line_type_id = ol.line_type_id(+) -- and l.org_id=:p_organization_id -- and l.line_category_code = 'ORDER' -- and l.service_reference_line_id is null /* Changed for bug#2597093 */ AND (l.service_reference_line_id IS NULL OR l.service_reference_type_code <> 'ORDER' OR (l.service_reference_type_code = 'ORDER' AND NOT EXISTS (SELECT header_id FROM oe_order_lines_all WHERE line_id = l.service_reference_line_id AND header_id = l.header_id))) AND l.order_quantity_uom = uom.uom_code(+) AND l.inventory_item_id = si.inventory_item_id AND NVL (si.organization_id, 0) = :c_master_org AND terms.term_id(+) = l.payment_term_id AND sr.salesrep_id(+) = l.salesrep_id --and a.agreement_id(+) = l.agreement_id AND lk1.lookup_code(+) = l.freight_terms_code AND lk1.lookup_type(+) = 'FREIGHT_TERMS' AND lk2.lookup_code(+) = l.fob_point_code AND lk2.lookup_type(+) = 'FOB' AND CSM.ship_method_code(+) = l.shipping_method_code AND NVL (CSM.organization_id(+), 0) = :c_master_org AND f.freight_code(+) = CSM.freight_code lk2.meaning, l.header_id, lk2.meaning, lk2.description l.header_id;
Query 8 Header Charges -----------------------XXFLS - Order Acknowledgement Report Boise - Concurrent Program Logic 13 of 24
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
SELECT sum(charge_amount) header_charge,CHARGE_NAME header_charge_name, header_id FROM oe_charge_lines_v GROUP BY header_id, CHARGE_NAME Query 9 Line Charges ----------------------
SELECT SUM(charge_amount) Line_Charge, CHARGE_NAME line_charge_name, header_id,line_id FROM oe_charge_lines_v WHERE line_id is not null GROUP BY header_id, line_id,CHARGE_NAME; Query 10 Line Service Reference --------------------------------SELECT NVL (svc_lin.unit_selling_price, 0) svc_selling_price, svc_lin.service_duration, (NVL (svc_lin.pricing_quantity, 0)) * NVL (svc_lin.unit_selling_price, 0) svc_extended_price, svc_lin.service_end_date, svc_lin.order_quantity_uom svc_unit_code, svc_lin.service_reference_line_id, svc_lin.tax_value tax_on_svc_line, mtl.description svc_item_description mtl_system_items_tl mtl, oe_order_lines_all svc_lin svc_lin.item_type_code = 'SERVICE' AND mtl.language = :p_user_lang AND NVL (svc_lin.org_id, 0) = NVL (:p_org_id, 0) AND svc_lin.inventory_item_id = mtl.inventory_item_id AND NVL (mtl.organization_id, 0) = :c_master_org
FROM WHERE
Validation Logic
Error Conditions:
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Warning Conditions:
Crash Recovery
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Integration Issues
Changes Required
Within Product Custom menus Other Products No changes required
Shared Components
INV None BOM None ENG None MPS/MRP None WIP None
Alert conditions
None.
Incompatibilities
None.
Performance Issues
None.
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Database Design
This section summarized new and changed database objects and data required supporting XXFLS - Order Acknowledgement Report Boise. However, the complete database design is documented in the Database Extensions Design document.
Descriptive Flexfields
Application: Form Name: Base Table:
Segment Name Prompt Size Value Set Default Value
Value Sets
Value Set OE: Number Zero Precision OE: Text ONT_SRS_ITEM_DISPLAY_CODE Siz e 38 30 50 Type SQL Statemen t Profile SQL Statemen t d Yes Yes Yes Rq Validation/Values
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
MD.070 Application Extension Technical Design Value Set OM: Yes or No ONT_SRS_ORDER_TYPE FND_NUMBER FND_STANDARD_DATE XXFLS_ONT_SRS_CUSTOMER_NA ME ONT_SRS_ORDER_CATEGORY ONT_SRS_LINE_CATEGORY ONT_SRS_SALESREPS ONT_SRS_AOL_USER WIP_SRS_NUMERIC_OPT Siz e 50 50 15 11 50 50 50 30 50 30 Type SQL Statemen t SQL Statemen t SQL Statemen t SQL Statemen t SQL Statemen t SQL Statemen t SQL Statemen t Rq Validation/Values
d Yes No No No No No No No No Yes
Profile
Grants/Synonyms
Owner Object Grantees
Archiving
No need to archive.
Database Diagram
No new tables
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Installation Requirements
Installation scripts must be prepared to perform the following actions in an automated way: 1. 2. 3. 4. 5. 6. 7. 8. 9. Create new tables. Insert seed data into <App Prefix>_SYNONYM as described above. Run grant/synonym script. Define Value Sets and Validation Tables. Define Descriptive Flexfields. Define Help text. Define Message text. Register Forms. Register Concurrent Programs.
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Implementation Notes
This document describes exactly how XXFLS - Order Acknowledgement Report Boise was developed and implemented at FLSmidth.
Design Summary
Functional Design
Technical Design
Design Review
Final Acceptance
Coding Summary
Development was done on <description of hardware>, to work with Release of Oracle Applications. All coding follows the standards defined in the Build Standards document for XXFS - Order Acknowledgement Report Boise Program Files The files required for this customization are as follows:
File Description Coded By
Testing Summary
The customizations were tested in FLSmidth's test environment before being moved to production. See the Link Test scripts for more information.
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
Installation
All modules are installed as if part of a separate product. A UNIX directory structure is created under $APPL_TOP as shown in the following example: $APPL_TOP | XXFLS | 1.0.0 ___________________________|___________________________________ | | | | | | | | | forms bin src sql log out srw install sql The directories contain the components of the enhancement as shown below (directories not listed are empty). All future customizations will also be stored in these directories. forms/ <Formname> bin/ src/ sql/ srw/ install/sql/ The forms and concurrent programs are registered in Application Object Library under the FLS Common application. A new set of menus (owned by XXFLS) is created to call the new forms as follows: The basic specifications are as follow Report Name : Boise Application : FLS Common RDF : XXFLS_ONT_OEXORDERACK_BOISE.rdf RTF XXFLS_ONT_OEXOORDER_BOISE.rtf Request Group: Responsibulity : Navigation: FLSUS978 OM Super User --> Reports --> Run Reports Name: XXFLS Order Acknowledgement - Boise OM Concurrent Programs FLSUS978 OM Super User : XXFLS Order Acknowledgement -
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only
ID
Issue
Resolution
Responsibility
Target Date
Impact Date
Closed Issues
ID
Issue
Resolution
Responsibility
Target Date
Impact Date
File Ref: 89091877.doc (v. 1.0) Company Confidential - For internal use only