DBA Data[Home] [Help]

PACKAGE: APPS.CSI_DIAGNOSTICS_PKG

Source


1 PACKAGE csi_diagnostics_pkg AUTHID CURRENT_USER as
2 /* $Header: csidiags.pls 120.5.12000000.1 2007/01/16 15:30:48 appldev ship $ */
3 
4   l_global_warning_flag varchar2(1) := 'N';
5   l_global_sync_flag    varchar2(1) := 'N';
6 
7   TYPE T_DATE  is TABLE OF DATE INDEX BY BINARY_INTEGER;
8   TYPE T_NUM   is TABLE OF NUMBER INDEX BY BINARY_INTEGER;
9   TYPE T_V1    is TABLE OF VARCHAR(01) INDEX BY BINARY_INTEGER;
10   TYPE T_V3    is TABLE OF VARCHAR(03) INDEX BY BINARY_INTEGER;
11   TYPE T_V10   is TABLE OF VARCHAR(10) INDEX BY BINARY_INTEGER;
12   TYPE T_V15   is TABLE OF VARCHAR(15) INDEX BY BINARY_INTEGER;
13   TYPE T_V20   is TABLE OF VARCHAR(20) INDEX BY BINARY_INTEGER;
14   TYPE T_V25   is TABLE OF VARCHAR(25) INDEX BY BINARY_INTEGER;
15   TYPE T_V30   is TABLE OF VARCHAR(30) INDEX BY BINARY_INTEGER;
16   TYPE T_V35   is TABLE OF VARCHAR(35) INDEX BY BINARY_INTEGER;
17   TYPE T_V40   is TABLE OF VARCHAR(40) INDEX BY BINARY_INTEGER;
18   TYPE T_V50   is TABLE OF VARCHAR(50) INDEX BY BINARY_INTEGER;
19   TYPE T_V60   is TABLE OF VARCHAR(60) INDEX BY BINARY_INTEGER;
20   TYPE T_V80   is TABLE OF VARCHAR(80) INDEX BY BINARY_INTEGER;
21   TYPE T_V85   is TABLE OF VARCHAR(85) INDEX BY BINARY_INTEGER;
22   TYPE T_V150  is TABLE OF VARCHAR(150) INDEX BY BINARY_INTEGER;
23   TYPE T_V240  is TABLE OF VARCHAR(240) INDEX BY BINARY_INTEGER;
24   TYPE T_V360  is TABLE OF VARCHAR(360) INDEX BY BINARY_INTEGER;
25   TYPE T_V1000 is TABLE OF VARCHAR(1000) INDEX BY BINARY_INTEGER;
26   TYPE T_V2000 is TABLE OF VARCHAR(2000) INDEX BY BINARY_INTEGER;
27   --
28   TYPE INSTANCE_REC_TAB IS RECORD
29      (
30 	INSTANCE_ID                  T_NUM
31        ,INSTANCE_NUMBER              T_V30
32        ,EXTERNAL_REFERENCE           T_V30
33        ,INVENTORY_ITEM_ID            T_NUM
34        ,VLD_ORGANIZATION_ID          T_NUM
35        ,INVENTORY_REVISION           T_V3
36        ,INV_MASTER_ORGANIZATION_ID   T_NUM
37        ,SERIAL_NUMBER                T_V30
38        ,MFG_SERIAL_NUMBER_FLAG       T_V1
39        ,LOT_NUMBER                   T_V80
40        ,QUANTITY                     T_NUM
41        ,UNIT_OF_MEASURE              T_V3
42        ,ACCOUNTING_CLASS_CODE        T_V10
43        ,INSTANCE_CONDITION_ID        T_NUM
44        ,INSTANCE_STATUS_ID           T_NUM
45        ,CUSTOMER_VIEW_FLAG           T_V1
46        ,MERCHANT_VIEW_FLAG           T_V1
47        ,SELLABLE_FLAG                T_V1
48        ,SYSTEM_ID                    T_NUM
49        ,INSTANCE_TYPE_CODE           T_V30
50        ,ACTIVE_START_DATE            T_DATE
51        ,ACTIVE_END_DATE              T_DATE
52        ,LOCATION_TYPE_CODE           T_V30
53        ,LOCATION_ID                  T_NUM
54        ,INV_ORGANIZATION_ID          T_NUM
55        ,INV_SUBINVENTORY_NAME        T_V10
56        ,INV_LOCATOR_ID               T_NUM
57        ,PA_PROJECT_ID                T_NUM
58        ,PA_PROJECT_TASK_ID           T_NUM
59        ,IN_TRANSIT_ORDER_LINE_ID     T_NUM
60        ,WIP_JOB_ID                   T_NUM
61        ,PO_ORDER_LINE_ID             T_NUM
62        ,LAST_OE_ORDER_LINE_ID        T_NUM
63        ,LAST_OE_RMA_LINE_ID          T_NUM
64        ,LAST_PO_PO_LINE_ID           T_NUM
65        ,LAST_OE_PO_NUMBER            T_V50
66        ,LAST_WIP_JOB_ID              T_NUM
67        ,LAST_PA_PROJECT_ID           T_NUM
68        ,LAST_PA_TASK_ID              T_NUM
69        ,LAST_OE_AGREEMENT_ID         T_NUM
70        ,INSTALL_DATE                 T_DATE
71        ,MANUALLY_CREATED_FLAG        T_V1
72        ,RETURN_BY_DATE               T_DATE
73        ,ACTUAL_RETURN_DATE           T_DATE
74        ,CREATION_COMPLETE_FLAG       T_V1
75        ,COMPLETENESS_FLAG            T_V1
76        ,VERSION_LABEL                T_V240
77        ,VERSION_LABEL_DESCRIPTION    T_V240
78        ,CONTEXT                      T_V30
79        ,ATTRIBUTE1                   T_V240
80        ,ATTRIBUTE2                   T_V240
81        ,ATTRIBUTE3                   T_V240
82        ,ATTRIBUTE4                   T_V240
83        ,ATTRIBUTE5                   T_V240
84        ,ATTRIBUTE6                   T_V240
85        ,ATTRIBUTE7                   T_V240
86        ,ATTRIBUTE8                   T_V240
87        ,ATTRIBUTE9                   T_V240
88        ,ATTRIBUTE10                  T_V240
89        ,ATTRIBUTE11                  T_V240
90        ,ATTRIBUTE12                  T_V240
91        ,ATTRIBUTE13                  T_V240
92        ,ATTRIBUTE14                  T_V240
93        ,ATTRIBUTE15                  T_V240
94        ,OBJECT_VERSION_NUMBER        T_NUM
95        ,LAST_TXN_LINE_DETAIL_ID      T_NUM
96        ,INSTALL_LOCATION_TYPE_CODE   T_V30
97        ,INSTALL_LOCATION_ID          T_NUM
98        ,INSTANCE_USAGE_CODE          T_V30
99        ,CHECK_FOR_INSTANCE_EXPIRY    T_V1
100        ,CALL_CONTRACTS               T_V1
101        ,GRP_CALL_CONTRACTS           T_V1
102        ,CONFIG_INST_HDR_ID           T_NUM
103        ,CONFIG_INST_REV_NUM          T_NUM
104        ,CONFIG_INST_ITEM_ID          T_NUM
105        ,CONFIG_VALID_STATUS          T_V30
106        ,INSTANCE_DESCRIPTION         T_V240
107      );
108   --
109   TYPE ii_relationship_rec_tab IS RECORD
110     (
111        RELATIONSHIP_ID               T_NUM
112       ,RELATIONSHIP_TYPE_CODE        T_V30
113       ,OBJECT_ID                     T_NUM
114       ,SUBJECT_ID                    T_NUM
115       ,SUBJECT_HAS_CHILD             T_V1
116       ,POSITION_REFERENCE            T_V30
117       ,ACTIVE_START_DATE             T_DATE
118       ,ACTIVE_END_DATE               T_DATE
119       ,DISPLAY_ORDER                 T_NUM
120       ,MANDATORY_FLAG                T_V1
121       ,CONTEXT                       T_V30
122       ,ATTRIBUTE1                    T_V150
123       ,ATTRIBUTE2                    T_V150
124       ,ATTRIBUTE3                    T_V150
125       ,ATTRIBUTE4                    T_V150
126       ,ATTRIBUTE5                    T_V150
127       ,ATTRIBUTE6                    T_V150
128       ,ATTRIBUTE7                    T_V150
129       ,ATTRIBUTE8                    T_V150
130       ,ATTRIBUTE9                    T_V150
131       ,ATTRIBUTE10                   T_V150
132       ,ATTRIBUTE11                   T_V150
133       ,ATTRIBUTE12                   T_V150
134       ,ATTRIBUTE13                   T_V150
135       ,ATTRIBUTE14                   T_V150
136       ,ATTRIBUTE15                   T_V150
137       ,OBJECT_VERSION_NUMBER         T_NUM
138   );
139   TYPE VERSION_LABEL_REC_TAB IS RECORD
140      (
141 	version_label_id            T_NUM
142        ,instance_id                 T_NUM
143        ,version_label               T_V240
144        ,description                 T_V240
145        ,date_time_stamp             T_DATE
146        ,active_start_date           T_DATE
147        ,active_end_date             T_DATE
148        ,context                     T_V30
149        ,attribute1                  T_V150
150        ,attribute2                  T_V150
151        ,attribute3                  T_V150
152        ,attribute4                  T_V150
153        ,attribute5                  T_V150
154        ,attribute6                  T_V150
155        ,attribute7                  T_V150
156        ,attribute8                  T_V150
157        ,attribute9                  T_V150
158        ,attribute10                 T_V150
159        ,attribute11                 T_V150
160        ,attribute12                 T_V150
161        ,attribute13                 T_V150
162        ,attribute14                 T_V150
163        ,attribute15                 T_V150
164        ,object_version_number       T_NUM
165      );
166   --
167   TYPE PARTY_REC_TAB IS RECORD
168      (
169 	instance_party_id                      T_NUM
170 	,instance_id                           T_NUM
171 	,party_source_table                    T_V30
172 	,party_id                              T_NUM
173 	,relationship_type_code                T_V30
174 	,contact_flag                          T_V1
175 	,contact_ip_id                         T_NUM
176 	,active_start_date                     T_DATE
177 	,active_end_date                       T_DATE
178 	,context                               T_V30
179 	,attribute1                            T_V150
180 	,attribute2                            T_V150
181 	,attribute3                            T_V150
182 	,attribute4                            T_V150
183 	,attribute5                            T_V150
184 	,attribute6                            T_V150
185 	,attribute7                            T_V150
186 	,attribute8                            T_V150
187 	,attribute9                            T_V150
188 	,attribute10                           T_V150
189 	,attribute11                           T_V150
190 	,attribute12                           T_V150
191 	,attribute13                           T_V150
192 	,attribute14                           T_V150
193 	,attribute15                           T_V150
194 	,object_version_number                 T_NUM
195 	,primary_flag                          T_V1
196 	,preferred_flag                        T_V1
197      );
198   --
199   TYPE ACCOUNT_REC_TAB IS RECORD
200      (
201 	ip_account_id                 T_NUM
202        ,parent_tbl_index              T_NUM
203        ,instance_party_id             T_NUM
204        ,party_account_id              T_NUM
205        ,relationship_type_code        T_V30
206        ,bill_to_address               T_NUM
207        ,ship_to_address               T_NUM
208        ,active_start_date             T_DATE
209        ,active_end_date               T_DATE
210        ,context                       T_V30
211        ,attribute1                    T_V150
212        ,attribute2                    T_V150
213        ,attribute3                    T_V150
214        ,attribute4                    T_V150
215        ,attribute5                    T_V150
216        ,attribute6                    T_V150
217        ,attribute7                    T_V150
218        ,attribute8                    T_V150
219        ,attribute9                    T_V150
220        ,attribute10                   T_V150
221        ,attribute11                   T_V150
222        ,attribute12                   T_V150
223        ,attribute13                   T_V150
224        ,attribute14                   T_V150
225        ,attribute15                   T_V150
226        ,object_version_number         T_NUM
227        ,call_contracts                T_V1
228        ,vld_organization_id           T_NUM
229        ,expire_flag                   T_V1
230      );
231   --
232   TYPE org_units_rec_tab IS RECORD
233      (
234 	instance_ou_id                 T_NUM
235        ,instance_id                    T_NUM
236        ,operating_unit_id              T_NUM
237        ,relationship_type_code         T_V30
238        ,active_start_date              T_DATE
239        ,active_end_date                T_DATE
240        ,context                        T_V30
241        ,attribute1                     T_V150
242        ,attribute2                     T_V150
243        ,attribute3                     T_V150
244        ,attribute4                     T_V150
245        ,attribute5                     T_V150
246        ,attribute6                     T_V150
247        ,attribute7                     T_V150
248        ,attribute8                     T_V150
249        ,attribute9                     T_V150
250        ,attribute10                    T_V150
251        ,attribute11                    T_V150
252        ,attribute12                    T_V150
253        ,attribute13                    T_V150
254        ,attribute14                    T_V150
255        ,attribute15                    T_V150
256        ,object_version_number          T_NUM
257      );
258   --
259   TYPE extend_attrib_values_rec_tab IS RECORD
260    (
261        attribute_value_id      T_NUM,
262        instance_id             T_NUM,
263        attribute_id            T_NUM,
264        attribute_code          T_V30,
265        attribute_value         T_V240,
266        active_start_date       T_DATE,
267        active_end_date         T_DATE,
268        context                 T_V30,
269        attribute1              T_V150,
270        attribute2              T_V150,
271        attribute3              T_V150,
272        attribute4              T_V150,
273        attribute5              T_V150,
274        attribute6              T_V150,
275        attribute7              T_V150,
276        attribute8              T_V150,
277        attribute9              T_V150,
278        attribute10             T_V150,
279        attribute11             T_V150,
280        attribute12             T_V150,
281        attribute13             T_V150,
282        attribute14             T_V150,
283        attribute15             T_V150,
284        object_version_number   T_NUM
285   );
286   --
287   TYPE instance_asset_rec_tab IS RECORD
288    (
289        instance_asset_id          T_NUM,
290        instance_id                T_NUM,
291        fa_asset_id                T_NUM,
292        fa_book_type_code          T_V15,
293        fa_location_id             T_NUM,
294        asset_quantity             T_NUM,
295        update_status              T_V30,
296        active_start_date          T_DATE,
297        active_end_date            T_DATE,
298        object_version_number      T_NUM,
299        check_for_instance_expiry  T_V1
300   );
301   --
302   TYPE PRICING_ATTRIBS_REC_TAB IS RECORD
303   (
304     pricing_attribute_id            T_NUM
305    ,instance_id                     T_NUM
306    ,active_start_date               T_DATE
307    ,active_end_date                 T_DATE
308    ,pricing_context                 T_V30
309    ,pricing_attribute1              T_V150
310    ,pricing_attribute2              T_V150
311    ,pricing_attribute3              T_V150
312    ,pricing_attribute4              T_V150
313    ,pricing_attribute5              T_V150
314    ,pricing_attribute6              T_V150
315    ,pricing_attribute7              T_V150
316    ,pricing_attribute8              T_V150
317    ,pricing_attribute9              T_V150
318    ,pricing_attribute10              T_V150
319    ,pricing_attribute11              T_V150
320    ,pricing_attribute12              T_V150
321    ,pricing_attribute13              T_V150
322    ,pricing_attribute14              T_V150
323    ,pricing_attribute15              T_V150
324    ,pricing_attribute16              T_V150
325    ,pricing_attribute17              T_V150
326    ,pricing_attribute18              T_V150
327    ,pricing_attribute19              T_V150
328    ,pricing_attribute20              T_V150
329    ,pricing_attribute21              T_V150
330    ,pricing_attribute22              T_V150
331    ,pricing_attribute23              T_V150
332    ,pricing_attribute24              T_V150
333    ,pricing_attribute25              T_V150
334    ,pricing_attribute26              T_V150
335    ,pricing_attribute27              T_V150
336    ,pricing_attribute28              T_V150
337    ,pricing_attribute29              T_V150
338    ,pricing_attribute30              T_V150
339    ,pricing_attribute31              T_V150
340    ,pricing_attribute32              T_V150
341    ,pricing_attribute33              T_V150
342    ,pricing_attribute34              T_V150
343    ,pricing_attribute35              T_V150
344    ,pricing_attribute36              T_V150
345    ,pricing_attribute37              T_V150
346    ,pricing_attribute38              T_V150
347    ,pricing_attribute39              T_V150
348    ,pricing_attribute40              T_V150
349    ,pricing_attribute41              T_V150
350    ,pricing_attribute42              T_V150
351    ,pricing_attribute43              T_V150
352    ,pricing_attribute44              T_V150
353    ,pricing_attribute45              T_V150
354    ,pricing_attribute46              T_V150
355    ,pricing_attribute47              T_V150
356    ,pricing_attribute48              T_V150
357    ,pricing_attribute49              T_V150
358    ,pricing_attribute50              T_V150
359    ,pricing_attribute51              T_V150
360    ,pricing_attribute52              T_V150
361    ,pricing_attribute53              T_V150
362    ,pricing_attribute54              T_V150
366    ,pricing_attribute58              T_V150
363    ,pricing_attribute55              T_V150
364    ,pricing_attribute56              T_V150
365    ,pricing_attribute57              T_V150
367    ,pricing_attribute59              T_V150
368    ,pricing_attribute60              T_V150
369    ,pricing_attribute61              T_V150
370    ,pricing_attribute62              T_V150
371    ,pricing_attribute63              T_V150
372    ,pricing_attribute64              T_V150
373    ,pricing_attribute65              T_V150
374    ,pricing_attribute66              T_V150
375    ,pricing_attribute67              T_V150
376    ,pricing_attribute68              T_V150
377    ,pricing_attribute69              T_V150
378    ,pricing_attribute70              T_V150
379    ,pricing_attribute71              T_V150
380    ,pricing_attribute72              T_V150
381    ,pricing_attribute73              T_V150
382    ,pricing_attribute74              T_V150
383    ,pricing_attribute75              T_V150
384    ,pricing_attribute76              T_V150
385    ,pricing_attribute77              T_V150
386    ,pricing_attribute78              T_V150
387    ,pricing_attribute79              T_V150
388    ,pricing_attribute80              T_V150
389    ,pricing_attribute81              T_V150
390    ,pricing_attribute82              T_V150
391    ,pricing_attribute83              T_V150
392    ,pricing_attribute84              T_V150
393    ,pricing_attribute85              T_V150
394    ,pricing_attribute86              T_V150
395    ,pricing_attribute87              T_V150
396    ,pricing_attribute88              T_V150
397    ,pricing_attribute89              T_V150
398    ,pricing_attribute90              T_V150
399    ,pricing_attribute91              T_V150
400    ,pricing_attribute92              T_V150
401    ,pricing_attribute93              T_V150
402    ,pricing_attribute94              T_V150
403    ,pricing_attribute95              T_V150
404    ,pricing_attribute96              T_V150
405    ,pricing_attribute97              T_V150
406    ,pricing_attribute98              T_V150
407    ,pricing_attribute99              T_V150
408    ,pricing_attribute100              T_V150
409    ,context                          T_V30
410    ,attribute1                       T_V150
411    ,attribute2                       T_V150
412    ,attribute3                       T_V150
413    ,attribute4                       T_V150
414    ,attribute5                       T_V150
415    ,attribute6                       T_V150
416    ,attribute7                       T_V150
417    ,attribute8                       T_V150
418    ,attribute9                       T_V150
419    ,attribute10                      T_V150
420    ,attribute11                      T_V150
421    ,attribute12                      T_V150
422    ,attribute13                      T_V150
423    ,attribute14                      T_V150
424    ,attribute15                      T_V150
425    ,object_version_number            T_NUM
426   );
427 
428    --Type rma_txn_rec is added for bug 5248037--
429   TYPE rma_txn_rec is RECORD(
430     Txn_error_id        number,
431     Mtl_Txn_id          number,
432     Item_id             number,
433     organization_id     number,
434     mtl_src_line_id     number,
435     mtl_creation_date   date,
436     mtl_txn_qty         number,
437     serial_code         number,
438     owner_acct          number,
439     ordered_qty         number,
440     ordered_uom         varchar2(30),
441     party_id            number
442   );
443 
444   TYPE rma_txn_tbl is TABLE OF rma_txn_rec INDEX BY BINARY_INTEGER;
445 
446   --Type instance_rec is added for bug 5248037--
447   TYPE instance_rec is RECORD(
448     Instance_id           number,
449     Quantity              number,
450     Active_start_date     date
451   );
452 
453   TYPE instance_tbl IS TABLE OF instance_rec INDEX BY BINARY_INTEGER;
454   PROCEDURE insert_full_dump(p_instance_id  IN NUMBER);
455   --
456 
457   PROCEDURE forward_sync;
458   --
459   PROCEDURE stage_soiship_instances;
460   --
461 
462   PROCEDURE get_rma_owner(
463     p_serial_number     in  varchar2,
464     p_inventory_item_id in  number,
465     p_organization_id   in  number,
466     x_change_owner_flag out nocopy varchar2,
467     x_owner_party_id    out nocopy number,
468     x_owner_account_id  out nocopy number);
469 
470   --
471   -- Data fix routines
472   PROCEDURE Delete_Dup_Relationship;
473   PROCEDURE Delete_Dup_Srl_Inv_Instance;
474   PROCEDURE Update_Instance_Usage;
475   PROCEDURE Update_Full_dump_flag;
476   PROCEDURE Del_API_Dup_Srl_Instance;
477   PROCEDURE Update_Vld_Organization;
478   PROCEDURE Update_Revision;
479   PROCEDURE Update_Dup_Srl_Instance;
480   PROCEDURE Delete_Dup_Account;
481   PROCEDURE Update_Instance_Party_Source;
482   PROCEDURE Update_Contact_Party_Record;
483   PROCEDURE Revert_Party_Rel_Type_Update;
484   PROCEDURE Update_Master_Organization_ID;
485   PROCEDURE Missing_MTL_Txn_ID_In_CSI;
486   PROCEDURE Delete_Dup_Org_Assignments;
487 
488   --
489   PROCEDURE Get_Next_Level
490     (p_object_id                 IN  NUMBER,
491      p_rel_tbl                   OUT NOCOPY csi_datastructures_pub.ii_relationship_tbl);
492   --
493   PROCEDURE Get_Children
494     (p_object_id     IN  NUMBER,
495      p_rel_tbl       OUT NOCOPY csi_datastructures_pub.ii_relationship_tbl);
496   --
497   PROCEDURE Call_Parallel_Expire(
498     errbuf         OUT NOCOPY VARCHAR2,
499     retcode        OUT NOCOPY NUMBER,
500     p_process_code IN VaRCHAR2);
501 
502   PROCEDURE decode_queue;
503 
504   PROCEDURE get_srldata(
505     p_single_error_flag  IN  varchar2 default 'N',
506     p_mtl_txn_id         IN  number default null);
507 
508   PROCEDURE preprocess_srldata;
509   PROCEDURE spool_srldata(p_mode in varchar2 default 'ALL');
510   PROCEDURE fix_srldata;
511   PROCEDURE sync_inv_serials;
512 
513   -- Non-serial specs
514   PROCEDURE Expire_Non_Trackable_Instance;
515   PROCEDURE Update_No_ctl_Srl_Lot_Inst;
516   PROCEDURE Create_or_Update_Shipping_Inst;
517   PROCEDURE IB_INV_Synch_Non_srl;
518   PROCEDURE Mark_Error_Transactions;
519   PROCEDURE Reverse_IB_INV_Synch;
520 
521   PROCEDURE fix_wip_usage;
522   PROCEDURE delete_dup_nsrl_wip_instances;
523   PROCEDURE get_nl_trackable_report;
524   PROCEDURE pump_all_missing_txns;
525   PROCEDURE pump_err_missing_txns;
526 
527   TYPE diag_txn_rec is RECORD(
528     diag_seq_id         number,
529     serial_number       varchar2(80),
530     item_id             number,
531     organization_id     number,
532     mtl_txn_id          number,
533     mtl_txn_date        date,
534     mtl_txn_qty         number,
535     mtl_creation_date   date,
536     mtl_xfer_txn_id     number,
537     serial_code         number,
538     lot_code            number,
539     revision_code       number,
540     csi_txn_id          number,
541     csi_txn_type_id     number,
542     internal_party_id   number,
543     wip_job_id          number,
544     source_type         varchar2(30),
545     inst_id             number,
546     create_flag         varchar2(1),
547     expire_flag         varchar2(1),
548     error_flag          varchar2(1),
549     marked_flag         varchar2(1),
550     process_flag        varchar2(1),
551     process_code        varchar2(10),
552     temp_message        varchar2(2000));
553 
554   TYPE diag_txn_tbl is TABLE OF diag_txn_rec INDEX BY BINARY_INTEGER;
555 
556  PROCEDURE Get_Non_Srl_RMA_Report
557    ( p_show_instances  IN   VARCHAR2);
558 
559   PROCEDURE MERGE_NON_SRL_INV_INSTANCE;
560 
561   PROCEDURE check_org_uniqueness;
562 
563   PROCEDURE fix_srlsoi_returned_serials;
564 
565   PROCEDURE fix_txn_error_rec;
566 
567   PROCEDURE IB_SYNC(
568     errbuf           OUT NOCOPY VARCHAR2,
569     retcode          OUT NOCOPY NUMBER,
570     p_show_instances IN  VARCHAR2,
571     p_mode           IN  VARCHAR2 default 'R', -- default is now 'R' shegde
572     p_force_data_fix IN  VARCHAR2 default 'N');
573 PROCEDURE create_oper_upd_manager
574   (x_errbuf         OUT  NOCOPY VARCHAR2,
575    x_retcode        OUT  NOCOPY VARCHAR2
576   );
577 PROCEDURE create_oper_upd_worker
578   (x_errbuf         OUT  NOCOPY VARCHAR2,
579    x_retcode        OUT  NOCOPY VARCHAR2,
580    x_batch_size     IN   NUMBER,
581    x_worker_id      IN   NUMBER,
582    x_num_workers    IN   NUMBER
583   );
584 END csi_diagnostics_pkg;