DBA Data[Home] [Help]

PACKAGE: APPS.BOM_RTG_PUB

Source


1 PACKAGE Bom_Rtg_Pub AS
2 /* $Header: BOMBRTGS.pls 120.5 2006/02/28 03:39:37 grastogi noship $ */
3 /*#
4  * APIs in this package are used to create, update or delete single or multiple
5  * Routings and any of its child entities. In addition, a number of utility
6  * procedures that convert Routing child entities to and from Bill of Materials
7  * child entities are provided. <BR> A Routing is composed of its header and
8  * optionally, a number of related child entities: routing revisions, operations, operation
9  * resources, substitute operation resources and operation networks. <BR>
10  * First, user creates the routing header for an Item. After creating
11  * the Header, user adds or updates or deletes operations and their child entities such as
12  * operation resources, substitute operation resources etc.
13  * This API can be used for processing a single or multiple business entities(Routing and its child entities)
14  * per call. The entities that needs to be processed should belong to the same Routing. How to use this is
15  * explained below through examples.<BR>
16  * Example 1 : To Create a new Routing entity.(Routing Header, Operation, Operation Resource etc).
17  *<li>1.The user should Initialize the Error_Handler so that errors can be logged and retrieved.</li>
18  *<li>2.The user populates the Record Type for each entity like Routing Header that needs to be processed.</li>
19  *<li>3.The record should be created with attribute values as explained in the record type description below.</li>
20  *<li>For example populate the Routing Header record by giving values as follows Routing_Header.transaction_type = 'CREATE'</li>
21  *<li>4.Then Process_Rtg procedure in this package is called with already created record types as paramters.</li>
22  *<li>This procedure processes the records and registers errors in the pl/sql error table, which can be
23  * extracted using Error_Hanlder.get_message procedure.</li>
24  *<li>5.If the Return Status is S then the process has completed sucessfully else error is logged by the Error_Handler.</li>
25  *<li>6.Upon Successful completion the user should commit the data.</li>
26  *
27  * Example-2 To Update the value of an attribute.
28  *<li>1.If the user wants to update the user unique index attributes like Operation Sequence Number for Operation Record Type,
29  * he should give the existing value to pick up the corrrect record and new value to change.</li>
30  *<li>rtg_operation.Operation_Sequence_Number = 10</li>
31  *<li>rtg_operation.New_Operation_Sequence_Number = 20</li>
32  *<li>2.If the user wants to update non-user unique indexes then only the new value is required.</li>
33  *<li>rtg_operation.Operation_Description = 'New Description'</li><BR>
34  *
35  * ----------------------
36  *  Routing Header Record
37  * ----------------------
38  *<code><pre>
39  * TYPE Rtg_Header_Rec_Type IS RECORD
40  * (
41  *   Assembly_Item_Name         VARCHAR2(240)
42  * , Organization_Code          VARCHAR2(3)
43  * , Alternate_Routing_Code     VARCHAR2(10)
44  * , Eng_Routing_Flag           NUMBER
45  * , Common_Assembly_Item_Name  VARCHAR2(240)
46  * , Routing_Comment            VARCHAR2(240)
47  * , Completion_Subinventory    VARCHAR2(10)
48  * , Completion_Location_Name   VARCHAR2(81)
49  * , Line_Code                  VARCHAR2(10)
50  * , CFM_Routing_Flag           NUMBER
51  * , Mixed_Model_Map_Flag       NUMBER
52  * , Priority                   NUMBER
53  * , Total_Cycle_Time           NUMBER
54  * , CTP_Flag                   NUMBER
55  * , Attribute_category         VARCHAR2(30)
56  * , Attribute1                 VARCHAR2(150)
57  * , Attribute2                 VARCHAR2(150)
58  * , Attribute3                 VARCHAR2(150)
59  * , Attribute4                 VARCHAR2(150)
60  * , Attribute5                 VARCHAR2(150)
61  * , Attribute6                 VARCHAR2(150)
62  * , Attribute7                 VARCHAR2(150)
63  * , Attribute8                 VARCHAR2(150)
64  * , Attribute9                 VARCHAR2(150)
65  * , Attribute10                VARCHAR2(150)
66  * , Attribute11                VARCHAR2(150)
67  * , Attribute12                VARCHAR2(150)
68  * , Attribute13                VARCHAR2(150)
69  * , Attribute14                VARCHAR2(150)
70  * , Attribute15                VARCHAR2(150)
71  * , Original_System_Reference  VARCHAR2(50)
72  * , Transaction_Type           VARCHAR2(30)
73  * , Return_Status              VARCHAR2(1)
74  * , Delete_Group_Name          VARCHAR2(10)
75  * , DG_Description             VARCHAR2(240)
76  * , Ser_Start_Op_Seq           NUMBER
77  * , Row_Identifier             NUMBER
78  * ) ;
79  *</pre></code>
80  *
81  * ------------------------------
82  *       Parameteres
83  * ------------------------------
84  *
85  *<pre>
86  * Assembly_item_name        -- User friendly name of the Item for which the Routing Header is created.
87  * Organization_Code         -- Organization Code in which the Item is defined.
88  * Alternate_Routing_Code    -- Routing name to be given. If null value is given, then the Routing is Primary.
89  * Eng_Routing_Flag          -- For Manufacturing Routing, Eng_Routing_Flag=1. For Engineering Routing, Eng_Routing_Flag=2.
90  * Common_Assembly_Item_Name -- Assembly Item name of common routing.
91  * Routing_Comment           -- Comment describing the Routing.
92  * Completion_Subinventory   -- Destination Subinventory for the Assembly.
93  * Completion_Location_Name  -- Destination Location for the Assembly.
94  * Line_Code                 -- User friendly name of a Line from WIP Lines used in Flow Manufacturing.
95  * CFM_Routing_Flag          -- Flag indicating whether the routing is Continous flow or traditional routing.
96  * Mixed_Model_Map_Flag      -- Flag indicating whether to use this routing in Mixed Model Map calculation. (1=Yes, 2=No)
97  * Priority                  -- Priority
98  * Total_Cycle_Time          -- Total time that an assembly takes along the primary path in the operation network, calculated by Flow Manufacturing.
99  * CTP_Flag                  -- Flag indicating capacity must be checked when item is ordered. (1=Yes, 2=No)
100  * Attribute_category        -- Descriptive flexfield structure defining column
101  * Attribute 1 to 15         -- Descriptive flexfield segments
102  * Original_System_Reference -- Original system that data for the current record has come from.
103  * Transaction_Type          -- Defined below
104  * Return_Status             -- The Routing Header creation status, whether successful or error
105  * Delete_Group_Name         -- Delete group name for the entity type you are deleting
106  * DG_Description            -- A meaningful description of the delete group
107  * Ser_Start_Op_Seq          -- Serialization Starting Operation Sequence Number for standard routings
108  * Row_Identifier            -- A unique identifier value for the entity record.
109  *</pre>
110  *
111  *
112  * -------------------------------
113  *    Routing Revision Record
114  * -------------------------------
115  *
116  *<code><pre>
117  * TYPE Rtg_Revision_Rec_Type  IS  RECORD
118  * (
119  *   Assembly_Item_Name         VARCHAR2(240)
120  * , Organization_Code          VARCHAR2(3)
121  * , Alternate_Routing_Code     VARCHAR2(10)
122  * , Revision                   VARCHAR2(3)
123  * , Start_Effective_Date       DATE
124  * , Attribute_category         VARCHAR2(30)
125  * , Attribute1                 VARCHAR2(150)
126  * , Attribute2                 VARCHAR2(150)
127  * , Attribute3                 VARCHAR2(150)
128  * , Attribute4                 VARCHAR2(150)
129  * , Attribute5                 VARCHAR2(150)
130  * , Attribute6                 VARCHAR2(150)
131  * , Attribute7                 VARCHAR2(150)
132  * , Attribute8                 VARCHAR2(150)
133  * , Attribute9                 VARCHAR2(150)
134  * , Attribute10                VARCHAR2(150)
135  * , Attribute11                VARCHAR2(150)
136  * , Attribute12                VARCHAR2(150)
137  * , Attribute13                VARCHAR2(150)
138  * , Attribute14                VARCHAR2(150)
139  * , Attribute15                VARCHAR2(150)
140  * , Original_System_Reference  VARCHAR2(50)
141  * , Transaction_Type           VARCHAR2(30)
142  * , Return_Status              VARCHAR2(1)
143  * , Row_Identifier             NUMBER
144  * )
145  *</pre></code>
146  *
147  * -----------------------
148  *     Parameters
149  * -----------------------
150  *
151  *<pre>
152  * Assembly_item_name           -- User friendly name of the Item for which the Routing is created.
153  * Organization_Code            -- Organization Code in which the Item is defined.
154  * Alternate_Routing_Code       -- Routing name, if null then Primary.
155  * Revision                     -- Routing Revision internal name
156  * Start_Effective_Date         -- Start Effectivity Date for the operation
157  * Attribute_category           -- Descriptive flexfield structure defining column
158  * Attribute 1 to 15            -- Descriptive flexfield segments
159  * Original_System_Reference    -- Original system that data for the current record has come from.
160  * Transaction_Type             -- Defined below
161  * Return_Status                -- The Routing Header creation status, whether successful or error
162  * Row_Identifier               -- A unique identifier value for the entity record.
163  *</pre>
164  *
165  * ----------------------------------
166  *   Routing Operation Record
167  * ----------------------------------
168  *
169  *<code><pre>
170  * TYPE Operation_Rec_Type   IS RECORD
171  * (
172  *   Assembly_Item_Name         VARCHAR2(240)
173  * , Organization_Code          VARCHAR2(3)
174  * , Alternate_Routing_Code     VARCHAR2(10)
175  * , Operation_Sequence_Number  NUMBER
176  * , Operation_Type             NUMBER
177  * , Start_Effective_Date       DATE
178  * , New_Operation_Sequence_Number NUMBER
179  * , New_Start_Effective_Date   DATE
180  * , Standard_Operation_Code    VARCHAR2(4)
181  * , Department_Code            VARCHAR2(10)
182  * , Op_Lead_Time_Percent       NUMBER
183  * , Minimum_Transfer_Quantity  NUMBER
184  * , Count_Point_Type           NUMBER
185  * , Operation_Description      VARCHAR2(240)
186  * , Disable_Date               DATE
187  * , Backflush_Flag             NUMBER
188  * , Option_Dependent_Flag      NUMBER
189  * , Reference_Flag             NUMBER
190  * , Process_Seq_Number         NUMBER
191  * , Process_Code               VARCHAR2(4)
192  * , Line_Op_Seq_Number         NUMBER
193  * , Line_Op_Code               VARCHAR2(4)
194  * , Yield                      NUMBER
195  * , Cumulative_Yield           NUMBER
196  * , Reverse_CUM_Yield          NUMBER
197  * , User_Labor_Time            NUMBER
198  * , User_Machine_Time          NUMBER
199  * , Net_Planning_Percent       NUMBER
200  * , Include_In_Rollup          NUMBER
201  * , Op_Yield_Enabled_Flag      NUMBER
202  * , Shutdown_Type              VARCHAR2(30)
203  * , Attribute_category         VARCHAR2(30)
204  * , Attribute1                 VARCHAR2(150)
205  * , Attribute2                 VARCHAR2(150)
206  * , Attribute3                 VARCHAR2(150)
207  * , Attribute4                 VARCHAR2(150)
208  * , Attribute5                 VARCHAR2(150)
209  * , Attribute6                 VARCHAR2(150)
210  * , Attribute7                 VARCHAR2(150)
211  * , Attribute8                 VARCHAR2(150)
212  * , Attribute9                 VARCHAR2(150)
213  * , Attribute10                VARCHAR2(150)
214  * , Attribute11                VARCHAR2(150)
215  * , Attribute12                VARCHAR2(150)
216  * , Attribute13                VARCHAR2(150)
217  * , Attribute14                VARCHAR2(150)
218  * , Attribute15                VARCHAR2(150)
219  * , Original_System_Reference  VARCHAR2(50)
220  * , Transaction_Type           VARCHAR2(30)
221  * , Return_Status              VARCHAR2(1)
222  * , Delete_Group_Name          VARCHAR2(10)
223  * , DG_Description             VARCHAR2(240)
224  * , Long_Description           VARCHAR2(4000)
225  * , Row_Identifier             NUMBER
226  * );
227  *</pre></code>
228  *
229  * -----------------------------
230  *       Parameters
231  * -----------------------------
232  *
233  *<pre>
234  * Assembly_item_name           -- User friendly name of the Item for which the Routing is created.
235  * Organization_Code            -- Organization Code in which the Item is defined.
236  * Alternate_Routing_Code       -- Routing name, if null then Primary.
237  * Operation_Sequence_Number    -- Routing Operation Sequence Number
238  * Operation_Type               -- Process, Line Operation or Event
239  * Start_Effective_Date         -- Start Effectivity Date for the operation
240  * New_Operation_Sequence_Number -- New Operation Sequence Number when existing Operation Sequence Number to be changed.
241  * New_Start_Effective_Date     -- New Start Effectivity Date
242  * Standard_Operation_Code      -- User friendly name of Standard Operation
243  * Department_Code              -- User friendly name of Department where the Operation is defined.
244  * Op_Lead_Time_Percent         -- Indicates the amount of overlap this operation's lead time has with the parent's lead time
245  * Minimum_Transfer_Quantity    -- Minimum Operation transfer quantity
246  * Count_Point_Type             -- 1=Yes - autocharge; 2=No - autocharge; 3=No - direct charge.
247  * Operation_Description        -- Meaningful description for the Operation
248  * Disable_Date                 -- The disable date after which the Operation will not be active
249  * Backflush_Flag               -- Indicates whether the Operation requires backflushing (1=Yes, 2=No)
250  * Option_Dependent_Flag        -- Indicates whether to use this Operation in all configuration routings, even if no components of the configuration are used in this Operation (1=Yes, 2=No)
251  * Reference_Flag               -- If the Standard Operation is referenced or copied then the operation can not be updated. (1=Yes, 2=No)
252  * Process_Seq_Number           -- Operation Sequence Number of parent process (applies only to events)
253  * Process_Code                 -- Operation Sequence Code of parent process (applies only to events)
254  * Line_Op_Seq_Number           -- Operation Sequence Number of the parent line operation
255  * Line_Op_Code                 -- Operation Sequence Code of the parent line operation
256  * Yield                        -- Process yield at this Operation
257  * Cumulative_Yield             -- Cumulative process yield from begining of routing to this operation
258  * Reverse_CUM_Yield            -- Cumulative process yield from end of routing to comparable operation
259  * User_Labor_Time              -- User calculated run time attributable to labor
260  * User_Machine_Time            -- User calculated run time attributable to machines
261  * Net_Planning_Percent         -- Cumulative planning percents derived from the operation network
262  * Include_In_Rollup            -- Indicates whether operation yield is to be considered in cost rollup (1=Yes, 2=No)
263  * Op_Yield_Enabled_Flag        -- Indicates whether operation yield is to be considered during costing (1=Yes, 2=No)
264  * Shutdown_Type                -- Shutdown type
265  * Attribute_category           -- Descriptive flexfield structure defining column
266  * Attribute 1 to 15            -- Descriptive flexfield segments
267  * Original_System_Reference    -- Original system that data for the current record has come from.
268  * Transaction_Type             -- Defined below
269  * Return_Status                -- The Routing Operation creation status, whether successful or error
270  * Delete_Group_Name            -- Delete group name for the entity type you are deleting
271  * DG_Description               -- A meaningful description of the delete group
272  * Long_Description             -- Long Description for Operation
273  * Row_Identifier               -- A unique identifier value for the entity record.
274  *</pre>
275  *
276  * ---------------------------------
277  *   Operation Resource Record
278  * ---------------------------------
279  *
280  *<code><pre>
281  * TYPE Op_Resource_Rec_Type IS RECORD
282  * (
283  *   Assembly_Item_Name         VARCHAR2(240)
284  * , Organization_Code          VARCHAR2(3)
285  * , Alternate_Routing_Code     VARCHAR2(10)
286  * , Operation_Sequence_Number  NUMBER
287  * , Operation_Type             NUMBER
288  * , Op_Start_Effective_Date    DATE
289  * , Resource_Sequence_Number   NUMBER
290  * , Resource_Code              VARCHAR2(10)
291  * , Activity                   VARCHAR2(10)
292  * , Standard_Rate_Flag         NUMBER
296  * , Basis_Type                 NUMBER
293  * , Assigned_Units             NUMBER
294  * , Usage_Rate_Or_Amount       NUMBER
295  * , Usage_Rate_Or_Amount_Inverse NUMBER
297  * , Schedule_Flag              NUMBER
298  * , Resource_Offset_Percent    NUMBER
299  * , Autocharge_Type            NUMBER
300  * , Substitute_Group_Number    NUMBER
301  * , Schedule_Sequence_Number   NUMBER
302  * , Principle_Flag             NUMBER
303  * , Attribute_category         VARCHAR2(30)
304  * , Attribute1                 VARCHAR2(150)
305  * , Attribute2                 VARCHAR2(150)
306  * , Attribute3                 VARCHAR2(150)
307  * , Attribute4                 VARCHAR2(150)
308  * , Attribute5                 VARCHAR2(150)
309  * , Attribute6                 VARCHAR2(150)
310  * , Attribute7                 VARCHAR2(150)
311  * , Attribute8                 VARCHAR2(150)
312  * , Attribute9                 VARCHAR2(150)
313  * , Attribute10                VARCHAR2(150)
314  * , Attribute11                VARCHAR2(150)
315  * , Attribute12                VARCHAR2(150)
316  * , Attribute13                VARCHAR2(150)
317  * , Attribute14                VARCHAR2(150)
318  * , Attribute15                VARCHAR2(150)
319  * , Original_System_Reference  VARCHAR2(50)
320  * , Transaction_Type           VARCHAR2(30)
321  * , Return_Status              VARCHAR2(1)
322  * , Setup_Type                 VARCHAR2(30)
323  * , Row_Identifier             NUMBER
324  * )
325  *</pre></code>
326  *
327  * -----------------------
328  *      Parameters
329  * -----------------------
330  *
331  *<pre>
332  * Assembly_item_name           -- User friendly name of the Item for which the Routing is created.
333  * Organization_Code            -- Organization Code in which the Item is defined.
334  * Alternate_Routing_Code       -- Routing name, if null then Primary.
335  * Operation_Sequence_Number    -- Routing Operation Sequence Number
336  * Operation_Type               -- Process, Line Operation or Event
337  * Op_Start_Effective_Date      -- Start Effectivity Date for the operation
338  * Resource_Sequence_Number     -- Resource Sequence Number to identify a resource in the Operation
339  * Resource_Code                -- User friendly name of the Resource
340  * Activity                     -- An activity to perform when the Resource is used.
341  * Standard_Rate_Flag           -- Indicate whether to use standard rate for shopfloor transactions (1=Yes, 2=No)
342  * Assigned_Units               -- Resource Units assigned to the Operation
343  * Usage_Rate_Or_Amount         -- Resource usage rate
344  * Usage_Rate_Or_Amount_Inverse -- Resource usage rate inverse
345  * Basis_Type                   -- Basis type identifier
346  * Schedule_Flag                -- Schedule the resource (1=Yes, 2=No, 3=Prior, 4=Next)
347  * Resource_Offset_Percent      -- Resource offset percent from the start of the routing
348  * Autocharge_Type              -- Autocharge type for shopfloor moves (1=WIP move, 2=Manual, 3=PO receipt, 4=PO move)
349  * Substitute_Group_Number      -- Substitute Group Number
350  * Schedule_Sequence_Number     -- Scheduling Sequence Number
351  * Principle_Flag               -- Principle Flag
352  * Attribute_category           -- Descriptive flexfield structure defining column
353  * Attribute 1 to 15            -- Descriptive flexfield segments
354  * Original_System_Reference    -- Original system that data for the current record has come from.
355  * Transaction_Type             -- Defined Below
356  * Return_Status                -- Process Status, whether successful or error
357  * Setup_Type                   -- Setup Type
358  * Row_Identifier               -- A unique identifier value for the entity record.
359  *</pre>
360  *
361  * ------------------------------------------
362  *    Substitute Operation Resource Record
363  * ------------------------------------------
364  *
365  *<code><pre>
366  * TYPE Sub_Resource_Rec_Type IS RECORD
367  * (
368  *   Assembly_Item_Name         VARCHAR2(240)
369  * , Organization_Code          VARCHAR2(3)
370  * , Alternate_Routing_Code     VARCHAR2(10)
371  * , Operation_Sequence_Number  NUMBER
372  * , Operation_Type             NUMBER
373  * , Op_Start_Effective_Date    DATE
374  * , Sub_Resource_Code          VARCHAR2(10)
375  * , New_Sub_Resource_Code      VARCHAR2(10)
376  * , Substitute_Group_Number    NUMBER
377  * , Schedule_Sequence_Number   NUMBER
378  * , Replacement_Group_Number   NUMBER
379  * , New_Replacement_Group_Number NUMBER
380  * , Activity                   VARCHAR2(10)
381  * , Standard_Rate_Flag         NUMBER
382  * , Assigned_Units             NUMBER
383  * , Usage_Rate_Or_Amount       NUMBER
384  * , Usage_Rate_Or_Amount_Inverse NUMBER
385  * , Basis_Type                 NUMBER
386  * , New_Basis_Type             NUMBER
387  * , Schedule_Flag              NUMBER
388  * , Resource_Offset_Percent    NUMBER
389  * , Autocharge_Type            NUMBER
390  * , Principle_Flag             NUMBER
391  * , Attribute_category         VARCHAR2(30)
392  * , Attribute1                 VARCHAR2(150)
393  * , Attribute2                 VARCHAR2(150)
394  * , Attribute3                 VARCHAR2(150)
395  * , Attribute4                 VARCHAR2(150)
396  * , Attribute5                 VARCHAR2(150)
397  * , Attribute6                 VARCHAR2(150)
398  * , Attribute7                 VARCHAR2(150)
399  * , Attribute8                 VARCHAR2(150)
403  * , Attribute12                VARCHAR2(150)
400  * , Attribute9                 VARCHAR2(150)
401  * , Attribute10                VARCHAR2(150)
402  * , Attribute11                VARCHAR2(150)
404  * , Attribute13                VARCHAR2(150)
405  * , Attribute14                VARCHAR2(150)
406  * , Attribute15                VARCHAR2(150)
407  * , Original_System_Reference  VARCHAR2(50)
408  * , Transaction_Type           VARCHAR2(30)
409  * , Return_Status              VARCHAR2(1)
410  * , Setup_Type                 VARCHAR2(30)
411  * , Row_Identifier             NUMBER
412  * )
413  *</pre></code>
414  *
415  * -----------------------
416  *     Parameters
417  * -----------------------
418  *
419  *<pre>
420  * Most of the parameters hold the same meaning as explained in Operation Resource record types. Those which are specific to
421  * this record type are
422  * Sub_Resource_Code            -- User friendly name of the Substitute Resource
423  * New_Sub_Resource_Code        -- User friendly name of the new Substitute Resource when existing Substitute Resource needs to be changed
424  * Replacement_Group_Number     -- Number to group the Substitute Resources
425  * New_Replacement_Group_Number -- New Replacement Group when existing Replacement Group Number needs to be changed
426  * New_Basis_Type               -- New Basis Type for updating existing Basis Type
427  *</pre>
428  *
429  * ------------------------------------------
430  *    Operation Network Record
431  * ------------------------------------------
432  *
433  *<code><pre>
434  * TYPE Op_Network_Rec_Type IS RECORD
435  * (
436  *   Assembly_Item_Name         VARCHAR2(240)
437  * , Organization_Code          VARCHAR2(3)
438  * , Alternate_Routing_Code     VARCHAR2(10)
439  * , Operation_Type             NUMBER
440  * , From_Op_Seq_Number         NUMBER
441  * , From_X_Coordinate          NUMBER
442  * , From_Y_Coordinate          NUMBER
443  * , From_Start_Effective_Date  DATE
444  * , To_Op_Seq_Number           NUMBER
445  * , To_X_Coordinate            NUMBER
446  * , To_Y_Coordinate            NUMBER
447  * , To_Start_Effective_Date    DATE
448  * , New_From_Op_Seq_Number     NUMBER
449  * , New_From_Start_Effective_Date DATE
450  * , New_To_Op_Seq_Number       NUMBER
451  * , New_To_Start_Effective_Date DATE
452  * , Connection_Type            NUMBER
453  * , Planning_Percent           NUMBER
454  * , Attribute_category         VARCHAR2(30)
455  * , Attribute1                 VARCHAR2(150)
456  * , Attribute2                 VARCHAR2(150)
457  * , Attribute3                 VARCHAR2(150)
458  * , Attribute4                 VARCHAR2(150)
459  * , Attribute5                 VARCHAR2(150)
460  * , Attribute6                 VARCHAR2(150)
461  * , Attribute7                 VARCHAR2(150)
462  * , Attribute8                 VARCHAR2(150)
463  * , Attribute9                 VARCHAR2(150)
464  * , Attribute10                VARCHAR2(150)
465  * , Attribute11                VARCHAR2(150)
466  * , Attribute12                VARCHAR2(150)
467  * , Attribute13                VARCHAR2(150)
468  * , Attribute14                VARCHAR2(150)
469  * , Attribute15                VARCHAR2(150)
470  * , Original_System_Reference  VARCHAR2(50)
471  * , Transaction_Type           VARCHAR2(30)
472  * , Return_Status              VARCHAR2(1)
473  * , Row_Identifier             NUMBER
474  *</pre></code>
475  *
476  * -----------------------
477  *     Parameters
478  * -----------------------
479  *
480  *<pre>
481  * Assembly_item_name             -- User friendly name of the Item for which the Routing is created.
482  * Organization_Code              -- Organization Code in which the Item is defined.
483  * Alternate_Routing_Code         -- Routing name, if null then Primary.
484  * Operation_Type                 -- Process, Line Operation or Event
485  * From_Op_Seq_Number             -- From Operation Sequence Number for the Network
486  * From_X_Coordinate              -- X Co-ordinate for From Operation
487  * From_Y_Coordinate              -- Y Co-ordinate for From Operation
488  * From_Start_Effective_Date      -- Effectivity Date for From Operation
489  * To_Op_Seq_Number               -- To Operation Sequence Number for the Network
490  * To_X_Coordinate                -- X Co-ordinate for To Operation
491  * To_Y_Coordinate                -- Y Co-ordinate for To Operation
492  * To_Start_Effective_Date        -- Effectivity Date for To Operation
493  * New_From_Op_Seq_Number         -- New From Operation Sequence Number for changing existing From Operation Sequence Number
494  * New_From_Start_Effective_Date  -- New From Effectivity Date for changing existing From Effectivity Date
495  * New_To_Op_Seq_Number           -- New To Operation Sequence Number for changing existing To Operation Sequence Number
496  * New_To_Start_Effective_Date    -- New To Effectivity Date for changing existing To Effectivity Date
497  * Connection_Type                -- Connection Type
498  * Planning_Percent               -- Planning Percent
499  * Original_System_Reference      -- Original system that data for the current record has come from.
500  * Transaction_Type               -- Defined Below
501  * Return_Status                  -- Process Status, whether successful or error
502  * Row_Identifier                 -- A unique identifier value for the entity record.
503  *</pre>
504  *
505  * Every entity that needs to be processed must have 'Transaction Type'.
509  * 2.Update the entity with the given values, if it exists.
506  * Valid Transaction Types are CREATE, UPDATE, DELETE and SYNC.
507  * The SYNC Transaction Type can be used when the requirement is:
508  * 1.Create an entity, if it does not exist.
510  *
511  * @rep:scope public
512  * @rep:product BOM
513  * @rep:lifecycle active
514  * @rep:displayname Create, Update or Delete Routing
515  * @rep:compatibility S
516  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
517  */
518 
519 /***************************************************************************
520 --
521 --  Copyright (c) 2000 Oracle Corporation, Redwood Shores, CA, USA
522 --  All rights reserved.
523 --
524 --  FILENAME
525 --
526 --      BOMBRTGS.pls
527 --
528 --  DESCRIPTION
529 --
530 --      Spec of package Bom_Rtg_Pub
531 --
532 --  NOTES
533 --
534 --  HISTORY
535 --
536 --   02-AUG-00  Biao Zhang         Initial Creation
537 --   08-AUG-00  Masanori Kimziuka  Modify and Add Conversion, Control_Rec_Type
538 --
539 ***************************************************************************/
540 
541 --
542 -- Routing Header exposed record definition
543 --
544 
545 TYPE Rtg_Header_Rec_Type IS RECORD
546    (
547      Assembly_Item_Name         VARCHAR2(240)   -- bug 2947642
548    , Organization_Code          VARCHAR2(3)
549    , Alternate_Routing_Code     VARCHAR2(10)
550    , Eng_Routing_Flag           NUMBER
551    , Common_Assembly_Item_Name  VARCHAR2(240) -- bug 2947642
552    , Routing_Comment            VARCHAR2(240)
553    , Completion_Subinventory    VARCHAR2(10)
554    , Completion_Location_Name   VARCHAR2(81)
555    , Line_Code                  VARCHAR2(10)
556    , CFM_Routing_Flag           NUMBER
557    , Mixed_Model_Map_Flag       NUMBER
558    , Priority                   NUMBER
559    , Total_Cycle_Time           NUMBER
560    , CTP_Flag                   NUMBER
561    , Attribute_category         VARCHAR2(30)
562    , Attribute1                 VARCHAR2(150)
563    , Attribute2                 VARCHAR2(150)
564    , Attribute3                 VARCHAR2(150)
565    , Attribute4                 VARCHAR2(150)
566    , Attribute5                 VARCHAR2(150)
567    , Attribute6                 VARCHAR2(150)
568    , Attribute7                 VARCHAR2(150)
569    , Attribute8                 VARCHAR2(150)
570    , Attribute9                 VARCHAR2(150)
571    , Attribute10                VARCHAR2(150)
572    , Attribute11                VARCHAR2(150)
573    , Attribute12                VARCHAR2(150)
574    , Attribute13                VARCHAR2(150)
575    , Attribute14                VARCHAR2(150)
576    , Attribute15                VARCHAR2(150)
577    , Original_System_Reference  VARCHAR2(50)
578    , Transaction_Type           VARCHAR2(30)
579    , Return_Status              VARCHAR2(1)
580    , Delete_Group_Name          VARCHAR2(10)
581    , DG_Description             VARCHAR2(240)
582    , Ser_Start_Op_Seq		NUMBER -- Added for SSOS
583    , Row_Identifier		NUMBER -- Added for Open Interface API
584    ) ;
585 --
586 -- Routing Unexposed Record definition
587 --
588    TYPE Rtg_Header_Unexposed_Rec_Type IS  RECORD
589    (
590      Routing_Sequence_Id          NUMBER
591    , Assembly_Item_Id             NUMBER
592    , Organization_Id              NUMBER
593    , Routing_Type                 NUMBER
594    , Common_Assembly_Item_Id      NUMBER
595    , Common_Routing_Sequence_Id   NUMBER
596    , Completion_Locator_Id        NUMBER
597    , Line_Id                      NUMBER
598    , DG_Sequence_Id               NUMBER
599    , DG_Description               VARCHAR2(240)
600    , DG_New                       BOOLEAN
601    );
602 
603 --
604 -- Routing_Revision exposed record definition
605 --
606 
607    TYPE Rtg_Revision_Rec_Type  IS  RECORD
608    (
609      Assembly_Item_Name         VARCHAR2(240) -- bug 2947642
610    , Organization_Code          VARCHAR2(3)
611    , Alternate_Routing_Code     VARCHAR2(10)
612    , Revision                   VARCHAR2(3)
613    , Start_Effective_Date       DATE
614    , Attribute_category         VARCHAR2(30)
615    , Attribute1                 VARCHAR2(150)
616    , Attribute2                 VARCHAR2(150)
617    , Attribute3                 VARCHAR2(150)
618    , Attribute4                 VARCHAR2(150)
619    , Attribute5                 VARCHAR2(150)
620    , Attribute6                 VARCHAR2(150)
621    , Attribute7                 VARCHAR2(150)
622    , Attribute8                 VARCHAR2(150)
623    , Attribute9                 VARCHAR2(150)
624    , Attribute10                VARCHAR2(150)
625    , Attribute11                VARCHAR2(150)
626    , Attribute12                VARCHAR2(150)
627    , Attribute13                VARCHAR2(150)
628    , Attribute14                VARCHAR2(150)
629    , Attribute15                VARCHAR2(150)
630    , Original_System_Reference  VARCHAR2(50)
631    , Transaction_Type           VARCHAR2(30)
632    , Return_Status              VARCHAR2(1)
633    , Row_Identifier		NUMBER -- Added for Open Interface API
634    ) ;
635 
636     TYPE Rtg_Revision_Tbl_Type IS TABLE OF Rtg_Revision_Rec_Type
637     INDEX BY BINARY_INTEGER ;
638 
639 --
640 -- Routing_Revison Unexposed Column Record
641 --
645      Routing_Sequence_Id  NUMBER
642 
643    TYPE Rtg_Rev_Unexposed_Rec_Type IS RECORD
644    (
646    , Assembly_Item_Id     NUMBER
647    , Organization_Id      NUMBER
648    , Implementation_Date  DATE
649    , Change_Notice        VARCHAR2(10)
650    ) ;
651 
652 -- ECO Uses a different record structure for Operation Seqeunces,
653 -- Operation Resources and Sub Operation Resources than what BOM Routing
654 -- uses. So their two control record definition
655 
656 
657 TYPE Control_Rec_Type IS RECORD
658     ( controlled_operation  BOOLEAN
659     , check_existence       BOOLEAN
660     , attribute_defaulting  BOOLEAN
661     , entity_defaulting     BOOLEAN
662     , entity_validation     BOOLEAN
663     , process_entity        VARCHAR2(30)
664     , write_to_db           BOOLEAN
665     , last_updated_by       NUMBER
666     , last_update_login     NUMBER
667     , caller_type           VARCHAR2(10)
668                         -- Set to 'FORM' if a FORM calls the program
669     , validation_controller VARCHAR2(30)
670                         -- The name a field that requires specific validation
671     , require_item_rev  NUMBER
672     , unit_controlled_item  BOOLEAN
673     );
674 
675     G_Default_Control_Rec  Control_Rec_Type ;
676 
677 --
678 -- Routing Operation exposed Column Record
679 --
680 
681    TYPE Operation_Rec_Type   IS RECORD
682    (
683      Assembly_Item_Name         VARCHAR2(240) -- bug 2947642
684    , Organization_Code          VARCHAR2(3)
685    , Alternate_Routing_Code     VARCHAR2(10)
686    , Operation_Sequence_Number  NUMBER
687    , Operation_Type             NUMBER
688    , Start_Effective_Date       DATE
689    , New_Operation_Sequence_Number NUMBER
690    , New_Start_Effective_Date   DATE
691    , Standard_Operation_Code    VARCHAR2(4)
692    , Department_Code            VARCHAR2(10)
693    , Op_Lead_Time_Percent       NUMBER
694    , Minimum_Transfer_Quantity  NUMBER
695    , Count_Point_Type           NUMBER
696    , Operation_Description      VARCHAR2(240)
697    , Disable_Date               DATE
698    , Backflush_Flag             NUMBER
699    , Option_Dependent_Flag      NUMBER
700    , Reference_Flag             NUMBER
701    , Process_Seq_Number         NUMBER
702    , Process_Code               VARCHAR2(4)
703    , Line_Op_Seq_Number         NUMBER
704    , Line_Op_Code               VARCHAR2(4)
705    , Yield                      NUMBER
706    , Cumulative_Yield           NUMBER
707    , Reverse_CUM_Yield          NUMBER
708    , User_Labor_Time            NUMBER
709    , User_Machine_Time          NUMBER
710    , Net_Planning_Percent       NUMBER
711    , Include_In_Rollup          NUMBER
712    , Op_Yield_Enabled_Flag      NUMBER
713    , Shutdown_Type              VARCHAR2(30)
714    , Attribute_category         VARCHAR2(30)
715    , Attribute1                 VARCHAR2(150)
716    , Attribute2                 VARCHAR2(150)
717    , Attribute3                 VARCHAR2(150)
718    , Attribute4                 VARCHAR2(150)
719    , Attribute5                 VARCHAR2(150)
720    , Attribute6                 VARCHAR2(150)
721    , Attribute7                 VARCHAR2(150)
722    , Attribute8                 VARCHAR2(150)
723    , Attribute9                 VARCHAR2(150)
724    , Attribute10                VARCHAR2(150)
725    , Attribute11                VARCHAR2(150)
726    , Attribute12                VARCHAR2(150)
727    , Attribute13                VARCHAR2(150)
728    , Attribute14                VARCHAR2(150)
729    , Attribute15                VARCHAR2(150)
730    , Original_System_Reference  VARCHAR2(50)
731    , Transaction_Type           VARCHAR2(30)
732    , Return_Status              VARCHAR2(1)
733    , Delete_Group_Name          VARCHAR2(10)
734    , DG_Description             VARCHAR2(240)
735    , Long_Description		VARCHAR2(4000) -- added for long description
736    , Row_Identifier		NUMBER -- Added for Open Interface API
737       );
738     TYPE Operation_Tbl_Type IS TABLE OF Operation_Rec_Type
739     INDEX BY BINARY_INTEGER ;
740 
741 --
742 -- Rouitng Operation Unexposed Column Record
743 --
744 
745    TYPE Op_Unexposed_Rec_Type    IS RECORD
746    (
747      Operation_Sequence_Id   NUMBER
748    , Routing_Sequence_Id     NUMBER
749    , Assembly_Item_Id        NUMBER
750    , Organization_Id         NUMBER
751    , Standard_Operation_Id   NUMBER
752    , Department_Id           NUMBER
753    , Process_Op_Seq_Id       NUMBER
754    , Line_Op_Seq_Id          NUMBER
755    , User_Elapsed_Time       NUMBER
756    , DG_Sequence_Id          NUMBER
757    , DG_Description          VARCHAR2(240)
758    , DG_New                  BOOLEAN
759    , Lowest_acceptable_yield NUMBER -- Added for MES Enhancement
760    , Use_org_settings	     NUMBER
761    , Queue_mandatory_flag    NUMBER
762    , Run_mandatory_flag      NUMBER
763    , To_move_mandatory_flag  NUMBER
764    , Show_next_op_by_default NUMBER
765    , Show_scrap_code         NUMBER
766    , Show_lot_attrib	     NUMBER
767    , Track_multiple_res_usage_dates NUMBER -- End of MES Changes
768    ) ;
769 
770 
771 --
772 -- Revised Operation exposed Column Record
773 --
774 
775    TYPE Rev_Operation_Rec_Type   IS RECORD
776    (
777      Eco_Name                   VARCHAR2(10)
778    , Organization_Code          VARCHAR2(3)
779    , Revised_Item_Name          VARCHAR2(240) -- bug 2947642
780    , New_Revised_Item_Revision  VARCHAR2(3)
781    , From_End_Item_Unit_Number  VARCHAR2(30)
782    , New_Routing_Revision       VARCHAR2(3)
783    , ACD_Type                   NUMBER
784    , Alternate_Routing_Code     VARCHAR2(10)
785    , Operation_Sequence_Number  NUMBER
786    , Operation_Type             NUMBER
787    , Start_Effective_Date       DATE
788    , New_Operation_Sequence_Number NUMBER
792    , Department_Code            VARCHAR2(10)
789    , Old_Operation_Sequence_Number NUMBER
790    , Old_Start_Effective_Date   DATE
791    , Standard_Operation_Code    VARCHAR2(4)
793    , Op_Lead_Time_Percent       NUMBER
794    , Minimum_Transfer_Quantity  NUMBER
795    , Count_Point_Type           NUMBER
796    , Operation_Description      VARCHAR2(240)
797    , Disable_Date               DATE
798    , Backflush_Flag             NUMBER
799    , Option_Dependent_Flag      NUMBER
800    , Reference_Flag             NUMBER
801    , Yield                      NUMBER
802    , Cumulative_Yield           NUMBER
803    , Cancel_Comments            VARCHAR2(240)
804    , Attribute_category         VARCHAR2(30)
805    , Attribute1                 VARCHAR2(150)
806    , Attribute2                 VARCHAR2(150)
807    , Attribute3                 VARCHAR2(150)
808    , Attribute4                 VARCHAR2(150)
809    , Attribute5                 VARCHAR2(150)
810    , Attribute6                 VARCHAR2(150)
811    , Attribute7                 VARCHAR2(150)
812    , Attribute8                 VARCHAR2(150)
813    , Attribute9                 VARCHAR2(150)
814    , Attribute10                VARCHAR2(150)
815    , Attribute11                VARCHAR2(150)
816    , Attribute12                VARCHAR2(150)
817    , Attribute13                VARCHAR2(150)
818    , Attribute14                VARCHAR2(150)
819    , Attribute15                VARCHAR2(150)
820    , Original_System_Reference  VARCHAR2(50)
821    , Transaction_Type           VARCHAR2(30)
822    , Return_Status              VARCHAR2(1)
823    ) ;
824 
825     TYPE Rev_Operation_Tbl_Type IS TABLE OF Rev_Operation_Rec_Type
826     INDEX BY BINARY_INTEGER ;
827 
828 --
829 -- Revised Operation Unexposed Column Record
830 --
831 
832    TYPE Rev_Op_Unexposed_Rec_Type    IS RECORD
833    (
834      Revised_Item_Sequence_Id    NUMBER
835    , Operation_Sequence_Id       NUMBER
836    , Old_Operation_Sequence_Id   NUMBER
837    , Routing_Sequence_Id         NUMBER
838    , Revised_Item_Id             NUMBER
839    , Organization_Id             NUMBER
840    , Standard_Operation_Id       NUMBER
841    , Department_Id               NUMBER
842    ) ;
843 
844 --
845 -- Common Operation exposed Column Record
846 --
847 
848    TYPE Com_Operation_Rec_Type   IS RECORD
849    (
850      Eco_Name                   VARCHAR2(10)
851    , Organization_Code          VARCHAR2(3)
852    , Revised_Item_Name          VARCHAR2(240) -- bug 2947642
853    , New_revised_Item_Revision  VARCHAR2(3)
854    , From_End_Item_Unit_Number  VARCHAR2(30)
855    , New_Routing_Revision       VARCHAR2(3)
856    , ACD_Type                   NUMBER
857    , Alternate_Routing_Code     VARCHAR2(10)
858    , Operation_Sequence_Number  NUMBER
859    , Operation_Type             NUMBER
860    , Start_Effective_Date       DATE
861    , New_Operation_Sequence_Number NUMBER
862    , New_Start_Effective_Date   DATE
863    , Old_Operation_Sequence_Number NUMBER
864    , Old_Start_Effective_Date   DATE
865    , Standard_Operation_Code    VARCHAR2(4)
866    , Department_Code            VARCHAR2(10)
867    , Op_Lead_Time_Percent       NUMBER
868    , Minimum_Transfer_Quantity  NUMBER
869    , Count_Point_Type           NUMBER
870    , Operation_Description      VARCHAR2(240)
871    , Disable_Date               DATE
872    , Backflush_Flag             NUMBER
873    , Option_Dependent_Flag      NUMBER
874    , Reference_Flag             NUMBER
875    , Process_Seq_Number         NUMBER
876    , Process_Code               VARCHAR2(4)
877    , Line_Op_Seq_Number         NUMBER
878    , Line_Op_Code               VARCHAR2(4)
879    , Yield                      NUMBER
880    , Cumulative_Yield           NUMBER
881    , Reverse_CUM_Yield          NUMBER
882    -- , Calculated_Labor_Time      NUMBER
883    -- , Calculated_Machine_Time    NUMBER
884    -- , Calculated_Elapsed_Time    NUMBER
885    , User_Labor_Time            NUMBER
886    , User_Machine_Time          NUMBER
887    -- , User_Elapsed_Time          NUMBER
888    , Net_Planning_Percent       NUMBER
889    , Include_In_Rollup          NUMBER
890    , Op_Yield_Enabled_Flag      NUMBER
891    , Cancel_Comments            VARCHAR2(240)
892      -- Added Shutdown_Type for eAM changes by MK on 04/10/2001
893    , Shutdown_Type              VARCHAR2(30)
894    , Attribute_category         VARCHAR2(30)
895    , Attribute1                 VARCHAR2(150)
896    , Attribute2                 VARCHAR2(150)
897    , Attribute3                 VARCHAR2(150)
898    , Attribute4                 VARCHAR2(150)
899    , Attribute5                 VARCHAR2(150)
900    , Attribute6                 VARCHAR2(150)
901    , Attribute7                 VARCHAR2(150)
902    , Attribute8                 VARCHAR2(150)
903    , Attribute9                 VARCHAR2(150)
904    , Attribute10                VARCHAR2(150)
905    , Attribute11                VARCHAR2(150)
906    , Attribute12                VARCHAR2(150)
907    , Attribute13                VARCHAR2(150)
908    , Attribute14                VARCHAR2(150)
909    , Attribute15                VARCHAR2(150)
910    , Original_System_Reference  VARCHAR2(50)
911    , Transaction_Type           VARCHAR2(30)
912    , Return_Status              VARCHAR2(1)
913    , Delete_Group_Name          VARCHAR2(10)
914    , DG_Description             VARCHAR2(240)
915    , Long_Description		VARCHAR2(4000) -- added for long description
916    ) ;
917 
918     TYPE  Com_Operation_Tbl_Type IS TABLE OF Rev_Operation_Rec_Type
919     INDEX BY BINARY_INTEGER ;
920 
921 --
922 -- Common Operation Unexposed Column Record
923 --
924 
928    , Operation_Sequence_Id       NUMBER
925    TYPE Com_Op_Unexposed_Rec_Type    IS RECORD
926    (
927      Revised_Item_Sequence_Id    NUMBER
929    , Old_Operation_Sequence_Id   NUMBER
930    , Routing_Sequence_Id         NUMBER
931    , Revised_Item_Id             NUMBER
932    , Organization_Id             NUMBER
933    , Standard_Operation_Id       NUMBER
934    , Department_Id               NUMBER
935    , Process_Op_Seq_Id           NUMBER
936    , Line_Op_Seq_Id              NUMBER
937    , User_Elapsed_Time           NUMBER
938    , DG_Sequence_Id              NUMBER
939    , DG_Description              VARCHAR2(240)
940    , DG_New                      BOOLEAN
941    , Lowest_acceptable_yield     NUMBER -- Added for MES Enhancement
942    , Use_org_settings	         NUMBER
943    , Queue_mandatory_flag        NUMBER
944    , Run_mandatory_flag          NUMBER
945    , To_move_mandatory_flag      NUMBER
946    , Show_next_op_by_default     NUMBER
947    , Show_scrap_code             NUMBER
948    , Show_lot_attrib	         NUMBER
949    , Track_multiple_res_usage_dates NUMBER -- End of MES Changes
950    ) ;
951 
952 
953 --
954 --  Operation Resource record type
955 --
956 
957    TYPE Op_Resource_Rec_Type IS RECORD
958    (
959      Assembly_Item_Name         VARCHAR2(240) -- bug 2947642
960    , Organization_Code          VARCHAR2(3)
961    , Alternate_Routing_Code     VARCHAR2(10)
962    , Operation_Sequence_Number  NUMBER
963    , Operation_Type             NUMBER
964    , Op_Start_Effective_Date    DATE
965    , Resource_Sequence_Number   NUMBER
966    , Resource_Code              VARCHAR2(10)
967    , Activity                   VARCHAR2(10)
968    , Standard_Rate_Flag         NUMBER
969    , Assigned_Units             NUMBER
970    , Usage_Rate_Or_Amount       NUMBER
971    , Usage_Rate_Or_Amount_Inverse   NUMBER
972    , Basis_Type                 NUMBER
973    , Schedule_Flag              NUMBER
974    , Resource_Offset_Percent    NUMBER
975    , Autocharge_Type            NUMBER
976    , Substitute_Group_Number    NUMBER  --added in RBO following changes for 11510
977    , Schedule_Sequence_Number   NUMBER
978    , Principle_Flag             NUMBER
979    , Attribute_category         VARCHAR2(30)
980    , Attribute1                 VARCHAR2(150)
981    , Attribute2                 VARCHAR2(150)
982    , Attribute3                 VARCHAR2(150)
983    , Attribute4                 VARCHAR2(150)
984    , Attribute5                 VARCHAR2(150)
985    , Attribute6                 VARCHAR2(150)
986    , Attribute7                 VARCHAR2(150)
987    , Attribute8                 VARCHAR2(150)
988    , Attribute9                 VARCHAR2(150)
989    , Attribute10                VARCHAR2(150)
990    , Attribute11                VARCHAR2(150)
991    , Attribute12                VARCHAR2(150)
992    , Attribute13                VARCHAR2(150)
993    , Attribute14                VARCHAR2(150)
994    , Attribute15                VARCHAR2(150)
995    , Original_System_Reference  VARCHAR2(50)
996    , Transaction_Type           VARCHAR2(30)
997    , Return_Status              VARCHAR2(1)
998    , Setup_Type                 VARCHAR2(30)
999    , Row_Identifier		NUMBER -- Added for Open Interface API
1000    ) ;
1001 
1002    TYPE Op_Resource_Tbl_Type IS  TABLE  OF Op_Resource_Rec_Type
1003                 INDEX BY BINARY_INTEGER;
1004 
1005 --
1006 --  Operation resource Unexposed Column Record
1007 --
1008 
1009    TYPE Op_Res_Unexposed_Rec_Type IS RECORD
1010    (
1011      Operation_Sequence_Id   NUMBER
1012    , Routing_Sequence_Id     NUMBER
1013    , Assembly_Item_Id        NUMBER
1014    , Organization_Id         NUMBER
1015    , Substitute_Group_Number NUMBER
1016    , Resource_Id             NUMBER
1017    , Activity_Id             NUMBER
1018    , Setup_Id                NUMBER
1019     );
1020 
1021 
1022 --
1023 --  Revised Operation Resource record type
1024 --
1025 
1026    TYPE Rev_Op_Resource_Rec_Type IS RECORD
1027    (
1028      Eco_Name                   VARCHAR2(10)
1029    , Organization_Code          VARCHAR2(3)
1030    , Revised_Item_Name          VARCHAR2(240) -- bug 2947642
1031    , New_Revised_Item_Revision  VARCHAR2(3)
1032    , From_End_Item_Unit_Number  VARCHAR2(30)   -- Added by MK on 11/02/00
1033    , New_Routing_Revision       VARCHAR2(3)    -- Added by MK on 11/02/00
1034    , ACD_Type                   NUMBER
1035    , Alternate_Routing_Code     VARCHAR2(10)
1036    , Operation_Sequence_Number  NUMBER
1037    , Operation_Type             NUMBER
1038    , Op_Start_Effective_Date    DATE
1039    , Resource_Sequence_Number   NUMBER
1040    , Resource_Code              VARCHAR2(10)
1041    , Activity                   VARCHAR2(10)
1042    , Standard_Rate_Flag         NUMBER
1043    , Assigned_Units             NUMBER
1044    , Usage_Rate_Or_Amount       NUMBER
1045    , Usage_Rate_Or_Amount_Inverse   NUMBER
1046    , Basis_Type                 NUMBER
1047    , Schedule_Flag              NUMBER
1048    , Resource_Offset_Percent    NUMBER
1049    , Autocharge_Type            NUMBER
1050    , Substitute_Group_Number    NUMBER
1051    , Schedule_Sequence_Number   NUMBER
1052    , Principle_Flag             NUMBER
1053    , Attribute_category         VARCHAR2(30)
1054    , Attribute1                 VARCHAR2(150)
1055    , Attribute2                 VARCHAR2(150)
1056    , Attribute3                 VARCHAR2(150)
1057    , Attribute4                 VARCHAR2(150)
1058    , Attribute5                 VARCHAR2(150)
1059    , Attribute6                 VARCHAR2(150)
1060    , Attribute7                 VARCHAR2(150)
1061    , Attribute8                 VARCHAR2(150)
1065    , Attribute12                VARCHAR2(150)
1062    , Attribute9                 VARCHAR2(150)
1063    , Attribute10                VARCHAR2(150)
1064    , Attribute11                VARCHAR2(150)
1066    , Attribute13                VARCHAR2(150)
1067    , Attribute14                VARCHAR2(150)
1068    , Attribute15                VARCHAR2(150)
1069    , Original_System_Reference  VARCHAR2(50)
1070    , Transaction_Type           VARCHAR2(30)
1071    , Return_Status              VARCHAR2(1)
1072    , Setup_Type                 VARCHAR2(30)
1073    ) ;
1074 
1075    TYPE Rev_Op_Resource_Tbl_Type IS  TABLE  OF Rev_Op_Resource_Rec_Type
1076    INDEX BY BINARY_INTEGER;
1077 
1078 --
1079 --  Revised Operation Resource Unexposed Column Record
1080 --
1081 
1082    TYPE Rev_Op_Res_Unexposed_Rec_Type IS RECORD
1083    (
1084      Revised_Item_Sequence_Id NUMBER
1085    , Operation_Sequence_Id    NUMBER
1086    , Routing_Sequence_Id      NUMBER
1087    , Revised_Item_Id          NUMBER
1088    , Organization_Id          NUMBER
1089    , Substitute_Group_Number  NUMBER
1090    , Resource_Id              NUMBER
1091    , Activity_Id              NUMBER
1092    , Setup_Id                 NUMBER
1093    ) ;
1094 
1095 
1096 --
1097 --  Substitute Operation Resource type
1098 --
1099 
1100    TYPE Sub_Resource_Rec_Type IS RECORD
1101    (
1102      Assembly_Item_Name         VARCHAR2(240) -- bug 2947642
1103    , Organization_Code          VARCHAR2(3)
1104    , Alternate_Routing_Code     VARCHAR2(10)
1105    , Operation_Sequence_Number  NUMBER
1106    , Operation_Type             NUMBER
1107    , Op_Start_Effective_Date    DATE
1108    , Sub_Resource_Code          VARCHAR2(10)
1109    , New_Sub_Resource_Code      VARCHAR2(10)
1110    , Substitute_Group_Number    NUMBER
1111    , Schedule_Sequence_Number   NUMBER
1112    , Replacement_Group_Number   NUMBER
1113    , New_Replacement_Group_Number NUMBER -- bug 3741570
1114    , Activity                   VARCHAR2(10)
1115    , Standard_Rate_Flag         NUMBER
1116    , Assigned_Units             NUMBER
1117    , Usage_Rate_Or_Amount       NUMBER
1118    , Usage_Rate_Or_Amount_Inverse   NUMBER
1119    , Basis_Type                 NUMBER
1120    , New_Basis_Type             NUMBER /* Added for bug 4689856 */
1121    , Schedule_Flag              NUMBER
1122    , Resource_Offset_Percent    NUMBER
1123    , Autocharge_Type            NUMBER
1124    , Principle_Flag             NUMBER
1125    , Attribute_category         VARCHAR2(30)
1126    , Attribute1                 VARCHAR2(150)
1127    , Attribute2                 VARCHAR2(150)
1128    , Attribute3                 VARCHAR2(150)
1129    , Attribute4                 VARCHAR2(150)
1130    , Attribute5                 VARCHAR2(150)
1131    , Attribute6                 VARCHAR2(150)
1132    , Attribute7                 VARCHAR2(150)
1133    , Attribute8                 VARCHAR2(150)
1134    , Attribute9                 VARCHAR2(150)
1135    , Attribute10                VARCHAR2(150)
1136    , Attribute11                VARCHAR2(150)
1137    , Attribute12                VARCHAR2(150)
1138    , Attribute13                VARCHAR2(150)
1139    , Attribute14                VARCHAR2(150)
1140    , Attribute15                VARCHAR2(150)
1141    , Original_System_Reference  VARCHAR2(50)
1142    , Transaction_Type           VARCHAR2(30)
1143    , Return_Status              VARCHAR2(1)
1144    , Setup_Type                 VARCHAR2(30)
1145    , Row_Identifier		NUMBER -- Added for Open Interface API
1146    ) ;
1147 
1148 
1149    TYPE Sub_Resource_Tbl_Type IS TABLE OF Sub_Resource_Rec_Type
1150    INDEX BY BINARY_INTEGER ;
1151 
1152 --
1153 --   Substitute Operation Resource Unexposed Column Record
1154 --
1155 
1156    TYPE Sub_Res_Unexposed_Rec_Type IS RECORD
1157    (
1158      Operation_Sequence_Id      NUMBER
1159    , Routing_Sequence_Id        NUMBER
1160    , Substitute_Group_Number    NUMBER
1161    , Assembly_Item_Id           NUMBER
1162    , Organization_Id            NUMBER
1163    , Resource_Id                NUMBER
1164    , New_Resource_Id            NUMBER
1165    , Activity_Id                NUMBER
1166    , Setup_Id                 NUMBER
1167    );
1168 
1169 
1170 
1171 --
1172 --  Revised Substitute Operation Resource type
1173 --
1174 
1175    TYPE Rev_Sub_Resource_Rec_Type IS RECORD
1176    (
1177      Eco_Name                   VARCHAR2(10)
1178    , Organization_Code          VARCHAR2(3)
1179    , Revised_Item_Name          VARCHAR2(240) -- bug 2947642
1180    , New_Revised_Item_Revision  VARCHAR2(3)
1181    , From_End_Item_Unit_Number  VARCHAR2(30)   -- Added by MK on 11/02/00
1182    , New_Routing_Revision       VARCHAR2(3)    -- Added by MK on 11/02/00
1183    , ACD_Type                   NUMBER
1184    , Alternate_Routing_Code     VARCHAR2(10)
1185    , Operation_Sequence_Number  NUMBER
1186    , Operation_Type             NUMBER
1187    , Op_Start_Effective_Date    DATE
1188    , Sub_Resource_Code          VARCHAR2(10)
1189    , New_Sub_Resource_Code      VARCHAR2(10)
1190    , Substitute_Group_Number    NUMBER
1191    , Schedule_Sequence_Number   NUMBER
1192    , Replacement_Group_Number   NUMBER
1193    , New_Replacement_Group_Number NUMBER -- bug 3741570
1194    , Activity                   VARCHAR2(10)
1195    , Standard_Rate_Flag         NUMBER
1196    , Assigned_Units             NUMBER
1197    , Usage_Rate_Or_Amount       NUMBER
1198    , Usage_Rate_Or_Amount_Inverse   NUMBER
1199    , Basis_Type                 NUMBER
1200    , New_Basis_Type             NUMBER /* Added for bug 4689856 */
1204    , Principle_Flag             NUMBER
1201    , Schedule_Flag              NUMBER
1202    , Resource_Offset_Percent    NUMBER
1203    , Autocharge_Type            NUMBER
1205    , Attribute_category         VARCHAR2(30)
1206    , Attribute1                 VARCHAR2(150)
1207    , Attribute2                 VARCHAR2(150)
1208    , Attribute3                 VARCHAR2(150)
1209    , Attribute4                 VARCHAR2(150)
1210    , Attribute5                 VARCHAR2(150)
1211    , Attribute6                 VARCHAR2(150)
1212    , Attribute7                 VARCHAR2(150)
1213    , Attribute8                 VARCHAR2(150)
1214    , Attribute9                 VARCHAR2(150)
1215    , Attribute10                VARCHAR2(150)
1216    , Attribute11                VARCHAR2(150)
1217    , Attribute12                VARCHAR2(150)
1218    , Attribute13                VARCHAR2(150)
1219    , Attribute14                VARCHAR2(150)
1220    , Attribute15                VARCHAR2(150)
1221    , Original_System_Reference  VARCHAR2(50)
1222    , Transaction_Type           VARCHAR2(30)
1223    , Return_Status              VARCHAR2(1)
1224    , Setup_Type                 VARCHAR2(30)
1225    ) ;
1226 
1227 
1228    TYPE Rev_Sub_Resource_Tbl_Type IS TABLE OF Rev_Sub_Resource_Rec_Type
1229    INDEX BY BINARY_INTEGER ;
1230 
1231 --
1232 --   Rev Substitute Operation Resource Unexposed Column Record
1233 --
1234 
1235    TYPE Rev_Sub_Res_Unexposed_Rec_Type IS RECORD
1236    (
1237      Revised_Item_Sequence_Id   NUMBER
1238    , Operation_Sequence_Id      NUMBER
1239    , Routing_Sequence_Id        NUMBER
1240    , Substitute_Group_Number    NUMBER
1241    , Revised_Item_Id            NUMBER
1242    , Organization_Id            NUMBER
1243    , Resource_Id                NUMBER
1244    , New_Resource_Id            NUMBER
1245    , Activity_Id                NUMBER
1246    , Setup_Id                 NUMBER
1247    ) ;
1248 
1249 --
1250 -- Operation Network Record definition
1251 --
1252    TYPE Op_Network_Rec_Type IS RECORD
1253    (
1254      Assembly_Item_Name         VARCHAR2(240) -- bug 2947642
1255    , Organization_Code          VARCHAR2(3)
1256    , Alternate_Routing_Code     VARCHAR2(10)
1257    , Operation_Type             NUMBER
1258    , From_Op_Seq_Number         NUMBER
1259    , From_X_Coordinate          NUMBER
1260    , From_Y_Coordinate          NUMBER
1261    , From_Start_Effective_Date  DATE
1262    , To_Op_Seq_Number           NUMBER
1263    , To_X_Coordinate            NUMBER
1264    , To_Y_Coordinate            NUMBER
1265    , To_Start_Effective_Date    DATE
1266    , New_From_Op_Seq_Number     NUMBER
1267    , New_From_Start_Effective_Date  DATE
1268    , New_To_Op_Seq_Number           NUMBER
1269    , New_To_Start_Effective_Date    DATE
1270    , Connection_Type            NUMBER
1271    , Planning_Percent           NUMBER
1272    , Attribute_category         VARCHAR2(30)
1273    , Attribute1                 VARCHAR2(150)
1274    , Attribute2                 VARCHAR2(150)
1275    , Attribute3                 VARCHAR2(150)
1276    , Attribute4                 VARCHAR2(150)
1277    , Attribute5                 VARCHAR2(150)
1278    , Attribute6                 VARCHAR2(150)
1279    , Attribute7                 VARCHAR2(150)
1280    , Attribute8                 VARCHAR2(150)
1281    , Attribute9                 VARCHAR2(150)
1282    , Attribute10                VARCHAR2(150)
1283    , Attribute11                VARCHAR2(150)
1284    , Attribute12                VARCHAR2(150)
1285    , Attribute13                VARCHAR2(150)
1286    , Attribute14                VARCHAR2(150)
1287    , Attribute15                VARCHAR2(150)
1288    , Original_System_Reference  VARCHAR2(50)
1289    , Transaction_Type           VARCHAR2(30)
1290    , Return_Status              VARCHAR2(1)
1291    , Row_Identifier		NUMBER -- Added for Open Interface API
1292    ) ;
1293 
1294      TYPE Op_Network_Tbl_Type IS TABLE OF Op_Network_Rec_Type
1295      INDEX BY BINARY_INTEGER;
1296 
1297 --
1298 -- Operation_Network Unexposed Record Definition
1299 --
1300 
1301    TYPE Op_Network_Unexposed_Rec_Type IS RECORD
1302    (
1303      From_Op_Seq_Id       NUMBER
1304    , To_Op_Seq_Id         NUMBER
1305    , New_From_Op_Seq_Id   NUMBER
1306    , New_To_Op_Seq_Id     NUMBER
1307    , Routing_Sequence_Id  NUMBER
1308    , CFM_Routing_Flag     VARCHAR2(1)
1309    , Assembly_Item_Id     NUMBER
1310    , Organization_Id      NUMBER
1311    ) ;
1312 
1313 
1314 --
1315 -- Missing Records for RTG BO
1316 --
1317    G_MISS_RTG_HEADER_REC         Bom_Rtg_Pub.Rtg_Header_Rec_Type ;
1318    G_MISS_RTG_REVISION_REC       Bom_Rtg_Pub.Rtg_Revision_Rec_Type ;
1319    G_MISS_OPERATION_REC          Bom_Rtg_Pub.Operation_Rec_Type ;
1320    G_MISS_OP_RESOURCE_REC        Bom_Rtg_Pub.Op_Resource_Rec_Type ;
1321    G_MISS_SUB_RESOURCE_REC       Bom_Rtg_Pub.Sub_Resource_Rec_Type ;
1322    G_MISS_OP_NETWORK_REC         Bom_Rtg_Pub.Op_Network_Rec_Type ;
1323 
1324    G_MISS_RTG_HEADER_UNEXP_REC   Bom_Rtg_Pub.Rtg_Header_Unexposed_Rec_Type ;
1325    G_MISS_RTG_REV_UNEXP_REC      Bom_Rtg_Pub.Rtg_Rev_Unexposed_Rec_Type ;
1326    G_MISS_OP_UNEXP_REC           Bom_Rtg_Pub.Op_Unexposed_Rec_Type ;
1327    G_MISS_OP_RES_UNEXP_REC       Bom_Rtg_Pub.Op_Res_Unexposed_Rec_Type ;
1328 
1329    G_MISS_SUB_RES_UNEXP_REC      Bom_Rtg_Pub.Sub_Res_Unexposed_Rec_Type ;
1330    G_MISS_OP_NETWORK_UNEXP_REC   Bom_Rtg_Pub.Op_Network_Unexposed_Rec_Type ;
1331 
1332    G_MISS_RTG_REVISION_TBL       Bom_Rtg_Pub.Rtg_Revision_Tbl_Type  ;
1333    G_MISS_OPERATION_TBL          Bom_Rtg_Pub.Operation_Tbl_Type;
1337 
1334    G_MISS_OP_RESOURCE_TBL        Bom_Rtg_Pub.Op_Resource_Tbl_Type ;
1335    G_MISS_SUB_RESOURCE_TBL       Bom_Rtg_Pub.Sub_Resource_Tbl_Type;
1336    G_MISS_OP_NETWORK_TBL         Bom_Rtg_Pub.Op_Network_Tbl_Type;
1338 --
1339 -- Missing Records for ENG BO
1340 --
1341 
1342    G_MISS_REV_OPERATION_REC          Bom_Rtg_Pub.Rev_Operation_Rec_Type ;
1343    G_MISS_REV_OP_RESOURCE_REC        Bom_Rtg_Pub.Rev_Op_Resource_Rec_Type ;
1344    G_MISS_REV_SUB_RESOURCE_REC       Bom_Rtg_Pub.Rev_Sub_Resource_Rec_Type ;
1345 
1346    G_MISS_REV_OP_UNEXP_REC           Bom_Rtg_Pub.Rev_Op_Unexposed_Rec_Type ;
1347    G_MISS_REV_OP_RES_UNEXP_REC       Bom_Rtg_Pub.Rev_Op_Res_Unexposed_Rec_Type ;
1348    G_MISS_REV_SUB_RES_UNEXP_REC      Bom_Rtg_Pub.Rev_Sub_Res_Unexposed_Rec_Type ;
1349 
1350    G_MISS_REV_OPERATION_TBL          Bom_Rtg_Pub.Rev_Operation_Tbl_Type;
1351    G_MISS_REV_OP_RESOURCE_TBL        Bom_Rtg_Pub.Rev_Op_Resource_Tbl_Type ;
1352    G_MISS_REV_SUB_RESOURCE_TBL       Bom_Rtg_Pub.Rev_Sub_Resource_Tbl_Type;
1353 
1354 
1355 --
1356 -- Missing Records for ENG BO
1357 --
1358 
1359    G_MISS_COM_OPERATION_REC          Bom_Rtg_Pub.Com_Operation_Rec_Type ;
1360    G_MISS_COM_OP_UNEXP_REC           Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type ;
1361    G_MISS_COM_OPERATION_TBL          Bom_Rtg_Pub.Com_Operation_Tbl_Type;
1362 
1363 
1364 --
1365 -- Conversion from Routing BO Entity to Eco BO Entity
1366 -- Conversion from Eco BO Entity to Routing BO Entity
1367 --
1368 
1369    -- Operation Entity
1370 
1371    -- From Routing To Common
1372 /*#
1373  * This procedure converts a Routing Operation into a Common Operation.
1374  *
1375  * @param p_rtg_operation_rec IN Routing Operation to be converted.
1376  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Operation_Rec_Type}
1377  * @param p_rtg_op_unexp_rec IN Routing Operation unexposed record.
1378  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Op_Unexposed_Rec_Type}
1379  * @param x_com_operation_rec IN OUT NOCOPY Converted Common Operation.
1380  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Operation_Rec_Type}
1381  * @param x_com_op_unexp_rec IN OUT NOCOPY Additional fields for converted Common Operation.
1382  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type}
1383  *
1384  * @rep:displayname Convert Routing Operation into Common Operation
1385  * @rep:scope private
1386  * @rep:lifecycle active
1387  * @rep:compatibility S
1388  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1389  */
1390    PROCEDURE Convert_RtgOp_To_ComOp
1391    (
1392      p_rtg_operation_rec  IN  Bom_Rtg_Pub.Operation_Rec_Type
1393    , p_rtg_op_unexp_rec   IN  Bom_Rtg_Pub.Op_Unexposed_Rec_Type
1394    , x_com_operation_rec  IN OUT NOCOPY Bom_Rtg_Pub.Com_Operation_Rec_Type
1395    , x_com_op_unexp_rec   IN OUT NOCOPY Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type
1396    ) ;
1397 
1398    -- From Common To Routing
1399 /*#
1400  * This procedure converts a Common Operation into a Routing Operation.
1401  *
1402  * @param p_com_operation_rec IN Common Operation to be converted.
1403  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Operation_Rec_Type}
1404  * @param p_com_op_unexp_rec IN Additional fields for Common Operation.
1405  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type}
1406  * @param x_rtg_operation_rec IN OUT NOCOPY Converted Routing Operation.
1407  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Operation_Rec_Type}
1408  * @param x_rtg_op_unexp_rec IN OUT NOCOPY Additional fields for converted Routing Operation.
1409  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Op_Unexposed_Rec_Type}
1410  *
1411  * @rep:displayname Convert Common Operation into Routing Operation
1412  * @rep:scope private
1413  * @rep:lifecycle active
1414  * @rep:compatibility S
1415  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1416  */
1417    PROCEDURE Convert_ComOp_To_RtgOp
1418    (
1419      p_com_operation_rec  IN  Bom_Rtg_Pub.Com_Operation_Rec_Type
1420    , p_com_op_unexp_rec IN  Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type
1421    , x_rtg_operation_rec  IN OUT NOCOPY Bom_Rtg_Pub.Operation_Rec_Type
1422    , x_rtg_op_unexp_rec   IN OUT NOCOPY Bom_Rtg_Pub.Op_Unexposed_Rec_Type
1423    ) ;
1424 
1425    -- From Eco To Common
1426 /*#
1427  * This procedure converts a revised operation into a common operation.
1428  *
1429  * @param p_rev_operation_rec IN Revised operation to be converted.
1430  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Operation_Rec_Type}
1431  * @param p_rev_op_unexp_rec IN Additional fields for revised operation to be converted.
1432  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Op_Unexposed_Rec_Type}
1433  * @param x_com_operation_rec IN OUT NOCOPY Converted common operation.
1434  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Operation_Rec_Type}
1435  * @param x_com_op_unexp_rec IN OUT NOCOPY Additional fields for converted common operation.
1436  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type}
1437  *
1438  * @rep:displayname Convert Revised Operation into Common Operation
1439  * @rep:scope private
1440  * @rep:lifecycle active
1441  * @rep:compatibility S
1442  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1443  */
1444    PROCEDURE Convert_EcoOp_To_ComOp
1445    (
1446      p_rev_operation_rec  IN  Bom_Rtg_Pub.Rev_Operation_Rec_Type
1447    , p_rev_op_unexp_rec IN  Bom_Rtg_Pub.Rev_Op_Unexposed_Rec_Type
1448    , x_com_operation_rec  IN OUT NOCOPY Bom_Rtg_Pub.Com_Operation_Rec_Type
1449    , x_com_op_unexp_rec   IN OUT NOCOPY Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type
1450    ) ;
1451 
1452 
1453    -- From Common To Eco
1454 /*#
1455  * This procedure converts a common operation into a revised operation.
1456  *
1457  * @param p_com_operation_rec IN Common operation to be converted.
1461  * @param x_rev_operation_rec IN OUT NOCOPY Converted Revised operation.
1458  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Operation_Rec_Type}
1459  * @param p_com_op_unexp_rec IN Additional fields for common operation.
1460  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type}
1462  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Operation_Rec_Type}
1463  * @param x_rev_op_unexp_rec IN OUT NOCOPY Additional fields for converted revised operation.
1464  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Op_Unexposed_Rec_Type}
1465  *
1466  * @rep:displayname Convert Common Operation into Revised Operation
1467  * @rep:scope private
1468  * @rep:lifecycle active
1469  * @rep:compatibility S
1470  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1471  */
1472    PROCEDURE Convert_ComOp_To_EcoOp
1473    (
1474      p_com_operation_rec  IN  Bom_Rtg_Pub.Com_Operation_Rec_Type
1475    , p_com_op_unexp_rec   IN  Bom_Rtg_Pub.Com_Op_Unexposed_Rec_Type
1476    , x_rev_operation_rec  IN OUT NOCOPY Bom_Rtg_Pub.Rev_Operation_Rec_Type
1477    , x_rev_op_unexp_rec   IN OUT NOCOPY Bom_Rtg_Pub.Rev_Op_Unexposed_Rec_Type
1478    ) ;
1479 
1480 
1481    -- Operation Resource Entity
1482 
1483 /*#
1484  * This procedure converts a routing operation resource into a revised operation resource.
1485  *
1486  * @param p_rtg_op_resource_rec IN Routing operation resource to be converted.
1487  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Op_Resource_Rec_Type}
1488  * @param p_rtg_op_res_unexp_rec IN Additional fields for routing operation resource to be converted.
1489  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Op_Res_Unexposed_Rec_Type}
1490  * @param x_rev_op_resource_rec IN OUT NOCOPY Converted revised operation resource.
1491  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Op_Resource_Rec_Type}
1492  * @param x_rev_op_res_unexp_rec IN OUT NOCOPY Additional fields for converted revised operation resource.
1493  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Op_Res_Unexposed_Rec_Type}
1494  *
1495  * @rep:displayname Convert Routing Operation Resource into Revised Operation Resource
1496  * @rep:scope private
1497  * @rep:lifecycle active
1498  * @rep:compatibility S
1499  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1500  */
1501    PROCEDURE Convert_RtgRes_To_EcoRes
1502    (
1503      p_rtg_op_resource_rec  IN Bom_Rtg_Pub.Op_Resource_Rec_Type
1504    , p_rtg_op_res_unexp_rec IN Bom_Rtg_Pub.Op_Res_Unexposed_Rec_Type
1505    , x_rev_op_resource_rec  IN OUT NOCOPY Bom_Rtg_Pub.Rev_Op_Resource_Rec_Type
1506    , x_rev_op_res_unexp_rec IN OUT NOCOPY Bom_Rtg_Pub.Rev_Op_Res_Unexposed_Rec_Type
1507    ) ;
1508 
1509 /*#
1510  * This procedure converts a revised operation resource into a routing operation resource.
1511  *
1512  * @param p_rev_op_resource_rec IN Revised operation resource to be converted.
1513  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Op_Resource_Rec_Type}
1514  * @param p_rev_op_res_unexp_rec IN Additional fields for revised operation resource to be converted.
1515  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Op_Res_Unexposed_Rec_Type}
1516  * @param x_rtg_op_resource_rec IN OUT NOCOPY Converted Routing operation resource.
1517  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Op_Resource_Rec_Type}
1518  * @param x_rtg_op_res_unexp_rec IN OUT NOCOPY Additional fields for converted routing operation.
1519  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Op_Res_Unexposed_Rec_Type}
1520  *
1521  * @rep:displayname Convert Revised Operation Resource into Routing Operation Resource
1522  * @rep:scope private
1523  * @rep:lifecycle active
1524  * @rep:compatibility S
1525  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1526  */
1527    PROCEDURE Convert_EcoRes_To_RtgRes
1528    (
1529      p_rev_op_resource_rec  IN  Bom_Rtg_Pub.Rev_Op_Resource_Rec_Type
1530    , p_rev_op_res_unexp_rec IN  Bom_Rtg_Pub.Rev_Op_Res_Unexposed_Rec_Type
1531    , x_rtg_op_resource_rec  IN OUT NOCOPY Bom_Rtg_Pub.Op_Resource_Rec_Type
1532    , x_rtg_op_res_unexp_rec IN OUT NOCOPY Bom_Rtg_Pub.Op_Res_Unexposed_Rec_Type
1533     ) ;
1534 
1535     -- Sub Operation Resource Entity
1536 
1537 /*#
1538  * This procedure converts a routing substitute resource into a revised substitute resource.
1539  *
1540  * @param p_rtg_sub_resource_rec IN Routing substitute resource to be converted.
1541  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Sub_Resource_Rec_Type}
1542  * @param p_rtg_sub_res_unexp_rec IN Additional fields for routing substitute resource to be converted.
1543  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Sub_Res_Unexposed_Rec_Type}
1544  * @param x_rev_sub_resource_rec IN OUT NOCOPY Converted revised substitute resource.
1545  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Sub_Resource_Rec_Type}
1546  * @param x_rev_sub_res_unexp_rec IN OUT NOCOPY Additional fields for converted revised substitute resource.
1547  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Sub_Res_Unexposed_Rec_Type}
1548  *
1549  * @rep:displayname Convert Routing Substitute Resource into Revised Substitute Resource
1550  * @rep:scope private
1551  * @rep:lifecycle active
1552  * @rep:compatibility S
1553  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1554  */
1555    PROCEDURE Convert_RtgSubRes_To_EcoSubRes
1556    (
1557      p_rtg_sub_resource_rec    IN  Bom_Rtg_Pub.Sub_Resource_Rec_Type
1558    , p_rtg_sub_res_unexp_rec   IN  Bom_Rtg_Pub.Sub_Res_Unexposed_Rec_Type
1559    , x_rev_sub_resource_rec    IN OUT NOCOPY Bom_Rtg_Pub.Rev_Sub_Resource_Rec_Type
1560    , x_rev_sub_res_unexp_rec   IN OUT NOCOPY Bom_Rtg_Pub.Rev_Sub_Res_Unexposed_Rec_Type
1561    ) ;
1562 
1563 /*#
1564  * This procedure converts a revised substitute resource into a routing substitute resource.
1565  *
1566  * @param p_rev_sub_resource_rec IN Revised substitute resource to be converted.
1567  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Sub_Resource_Rec_Type}
1568  * @param p_rev_sub_res_unexp_rec IN Additional fields for revised substitute resource to be converted.
1569  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Rev_Sub_Res_Unexposed_Rec_Type}
1573  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Sub_Res_Unexposed_Rec_Type}
1570  * @param x_rtg_sub_resource_rec IN OUT NOCOPY Converted Routing substitute resource.
1571  * @rep:paraminfo {@rep:innertype Bom_Rtg_Pub.Sub_Resource_Rec_Type}
1572  * @param x_rtg_sub_res_unexp_rec IN OUT NOCOPY Additional fields for converted routing substitute resource.
1574  *
1575  * @rep:displayname Convert Revised Substitute Resource into Routing Substitute Resource
1576  * @rep:scope private
1577  * @rep:lifecycle active
1578  * @rep:compatibility S
1579  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1580  */
1581    PROCEDURE Convert_EcoSubRes_To_RtgSubRes
1582    (
1583      p_rev_sub_resource_rec  IN  Bom_Rtg_Pub.Rev_Sub_Resource_Rec_Type
1584    , p_rev_sub_res_unexp_rec IN  Bom_Rtg_Pub.Rev_Sub_Res_Unexposed_Rec_Type
1585    , x_rtg_sub_resource_rec  IN OUT NOCOPY Bom_Rtg_Pub.Sub_Resource_Rec_Type
1586    , x_rtg_sub_res_unexp_rec IN OUT NOCOPY Bom_Rtg_Pub.Sub_Res_Unexposed_Rec_Type
1587    ) ;
1588 
1589 
1590 
1591 /*#
1592  * This procedure is used to create, update or delete a routing
1593  * and its child entities:routing revisions, operations, operation
1594  * resources, substitute operation resources and operation networks.
1595  * Each of the records contained in one of the tables
1596  * passed as a parameter contains a <code>TRANSACTION_TYPE</code> field, which
1597  * indicates the operation to be performed on the record, as follows:
1598  * <UL>
1599  * <LI><code><B>TRANSACTION_TYPE = 'CREATE'</B></code> for record creation</LI>
1600  * <LI><code><B>TRANSACTION_TYPE = 'UPDATE'</B></code> for record update</LI>
1601  * <LI><code><B>TRANSACTION_TYPE = 'DELETE'</B></code> for record deletion</LI>
1602  * </UL>
1603  *
1604  * @param p_bo_identifier IN Business Object identifier. Possible values are RTG and ECO.
1605  * @param p_api_version_number IN API version number.
1606  * @param p_init_msg_list IN Use TRUE if you want to initialize the FND_MSG_PUB
1607  * package's message stack on calling the procedure.
1608  * @param p_rtg_header_rec IN Manufacturing routing header, corresponding to the
1609  * business object instance.
1610  * @param p_rtg_revision_tbl IN Manufacturing routing revisions.
1611  * @param p_operation_tbl IN Manufacturing routing operations.
1612  * @param p_op_resource_tbl IN Manufacturing routing operation resources.
1613  * @param p_sub_resource_tbl IN Manufacturing routing substitute operation
1614  * resources.
1615  * @param p_op_network_tbl IN Manufacturing routing operation networks.
1616  * @param x_rtg_header_rec IN OUT NOCOPY Resulting manufacturing routing header.
1617  * @param x_rtg_revision_tbl IN OUT NOCOPY Resulting manufacturing routing revisions.
1618  * @param x_operation_tbl IN OUT NOCOPY Resulting manufacturing routing operations.
1619  * @param x_op_resource_tbl IN OUT NOCOPY Resulting manufacturing routing operation resources.
1620  * @param x_sub_resource_tbl IN OUT NOCOPY Resulting manufacturing routing substitute operation
1621  * resources.
1622  * @param x_op_network_tbl IN OUT NOCOPY Resulting manufacturing routing operation networks.
1623  * @param x_return_status IN OUT NOCOPY Return status: 'S' for success, 'E' for error, 'U' for
1624  * unexpected error.
1625  * @param x_msg_count IN OUT NOCOPY Number of messages produced by the API.
1626  * @param p_debug IN Debuggin is enabled or not
1627  * @param p_output_dir IN Path of the debug output directory
1628  * @param p_debug_filename IN File name of the debug file
1629  *
1630  * @rep:displayname Process Routing
1631  * @rep:scope public
1632  * @rep:lifecycle active
1633  * @rep:compatibility S
1634  * @rep:category BUSINESS_ENTITY BOM_MFG_ROUTING
1635  */
1636    PROCEDURE Process_Rtg
1637    ( p_bo_identifier           IN  VARCHAR2 := 'RTG'
1638    , p_api_version_number      IN  NUMBER := 1.0
1639    , p_init_msg_list           IN  BOOLEAN := FALSE
1640    , p_rtg_header_rec          IN  Bom_Rtg_Pub.Rtg_Header_Rec_Type
1641                                         :=Bom_Rtg_Pub.G_MISS_RTG_HEADER_REC
1642    , p_rtg_revision_tbl        IN  Bom_Rtg_Pub.Rtg_Revision_Tbl_Type
1643                                         :=Bom_Rtg_Pub.G_MISS_RTG_REVISION_TBL
1644    , p_operation_tbl           IN  Bom_Rtg_Pub.Operation_Tbl_Type
1645                                         :=  Bom_Rtg_Pub.G_MISS_OPERATION_TBL
1646    , p_op_resource_tbl         IN  Bom_Rtg_Pub.Op_Resource_Tbl_Type
1647                                         :=  Bom_Rtg_Pub.G_MISS_OP_RESOURCE_TBL
1648    , p_sub_resource_tbl        IN  Bom_Rtg_Pub.Sub_Resource_Tbl_Type
1649                                        :=  Bom_Rtg_Pub.G_MISS_SUB_RESOURCE_TBL
1650    , p_op_network_tbl          IN  Bom_Rtg_Pub.Op_Network_Tbl_Type
1651                                         :=  Bom_Rtg_Pub.G_MISS_OP_NETWORK_TBL
1652    , x_rtg_header_rec          IN OUT NOCOPY Bom_Rtg_Pub.Rtg_Header_Rec_Type
1653    , x_rtg_revision_tbl        IN OUT NOCOPY Bom_Rtg_Pub.Rtg_Revision_Tbl_Type
1654    , x_operation_tbl           IN OUT NOCOPY Bom_Rtg_Pub.Operation_Tbl_Type
1655    , x_op_resource_tbl         IN OUT NOCOPY Bom_Rtg_Pub.Op_Resource_Tbl_Type
1656    , x_sub_resource_tbl        IN OUT NOCOPY Bom_Rtg_Pub.Sub_Resource_Tbl_Type
1657    , x_op_network_tbl          IN OUT NOCOPY Bom_Rtg_Pub.Op_Network_Tbl_Type
1658    , x_return_status           IN OUT NOCOPY VARCHAR2
1659    , x_msg_count               IN OUT NOCOPY NUMBER
1660    , p_debug                   IN  VARCHAR2 := 'N'
1661    , p_output_dir              IN  VARCHAR2 := NULL
1662    , p_debug_filename          IN  VARCHAR2 := 'RTG_BO_debug.log'
1663    ) ;
1664 
1665 END Bom_Rtg_Pub ;