51:
52: n_dname := substrb('@'||l_dname, 1, 80);
53:
54: if ( n_dname = l_dname ) then
55: Wf_Core.Token('DNAME', x_display_name);
56: Wf_Core.Token('NAME', x_name);
57: Wf_Core.Token('CONFLICT_NAME', conflict_name);
58: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
59: exit;
52: n_dname := substrb('@'||l_dname, 1, 80);
53:
54: if ( n_dname = l_dname ) then
55: Wf_Core.Token('DNAME', x_display_name);
56: Wf_Core.Token('NAME', x_name);
57: Wf_Core.Token('CONFLICT_NAME', conflict_name);
58: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
59: exit;
60: end if;
53:
54: if ( n_dname = l_dname ) then
55: Wf_Core.Token('DNAME', x_display_name);
56: Wf_Core.Token('NAME', x_name);
57: Wf_Core.Token('CONFLICT_NAME', conflict_name);
58: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
59: exit;
60: end if;
61: exception
54: if ( n_dname = l_dname ) then
55: Wf_Core.Token('DNAME', x_display_name);
56: Wf_Core.Token('NAME', x_name);
57: Wf_Core.Token('CONFLICT_NAME', conflict_name);
58: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
59: exit;
60: end if;
61: exception
62: when no_data_found then
72: -- where NAME = l_name
73: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
74: -- exception
75: -- when others then
76: -- Wf_Core.Token('TABLE', 'ITEM_TYPES_TL');
77: -- Wf_Core.Token('VALUE', l_name);
78: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
79: -- end;
80: exception
73: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
74: -- exception
75: -- when others then
76: -- Wf_Core.Token('TABLE', 'ITEM_TYPES_TL');
77: -- Wf_Core.Token('VALUE', l_name);
78: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
79: -- end;
80: exception
81: when no_data_found then
74: -- exception
75: -- when others then
76: -- Wf_Core.Token('TABLE', 'ITEM_TYPES_TL');
77: -- Wf_Core.Token('VALUE', l_name);
78: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
79: -- end;
80: exception
81: when no_data_found then
82: null;
91: into protection_level, customization_level
92: from WF_ITEM_TYPES_VL
93: where NAME = x_name;
94:
95: if ((wf_core.upload_mode <> 'FORCE') and
96: (protection_level < wf_core.session_level)) then
97: x_level_error := 1;
98: return;
99: end if;
92: from WF_ITEM_TYPES_VL
93: where NAME = x_name;
94:
95: if ((wf_core.upload_mode <> 'FORCE') and
96: (protection_level < wf_core.session_level)) then
97: x_level_error := 1;
98: return;
99: end if;
100:
97: x_level_error := 1;
98: return;
99: end if;
100:
101: if ((wf_core.upload_mode = 'UPGRADE') and
102: (customization_level > wf_core.session_level)) then
103: x_level_error := 2;
104: return;
105: end if;
98: return;
99: end if;
100:
101: if ((wf_core.upload_mode = 'UPGRADE') and
102: (customization_level > wf_core.session_level)) then
103: x_level_error := 2;
104: return;
105: end if;
106:
120: );
121: exception
122: when NO_DATA_FOUND then
123: -- Check protection level for new row
124: if ((wf_core.upload_mode <> 'FORCE') and
125: (x_protect_level < wf_core.session_level)) then
126: x_level_error := 4+1;
127: return;
128: end if;
121: exception
122: when NO_DATA_FOUND then
123: -- Check protection level for new row
124: if ((wf_core.upload_mode <> 'FORCE') and
125: (x_protect_level < wf_core.session_level)) then
126: x_level_error := 4+1;
127: return;
128: end if;
129:
126: x_level_error := 4+1;
127: return;
128: end if;
129:
130: if ((wf_core.upload_mode = 'UPGRADE') and
131: (x_custom_level > wf_core.session_level)) then
132: x_level_error := 4+2;
133: return;
134: end if;
127: return;
128: end if;
129:
130: if ((wf_core.upload_mode = 'UPGRADE') and
131: (x_custom_level > wf_core.session_level)) then
132: x_level_error := 4+2;
133: return;
134: end if;
135:
152:
153:
154: exception
155: when OTHERS then
156: Wf_Core.Context('Wf_Load', 'Upload_Item_Type', x_name);
157: raise;
158: end UPLOAD_ITEM_TYPE;
159:
160: --
204: and SEQUENCE = -1;
205:
206: exception
207: when others then
208: Wf_Core.Context('Wf_Load', 'Reseq_Item_Attribute', itemtype,
209: to_char(oldseq), to_char(newseq));
210: raise;
211: end Reseq_Item_Attribute;
212:
269:
270: n_dname := substrb('@'||l_dname, 1, 80);
271:
272: if ( n_dname = l_dname ) then
273: Wf_Core.Token('DNAME', x_display_name);
274: Wf_Core.Token('NAME', x_item_type||':'||x_name);
275: Wf_Core.Token('CONFLICT_NAME', conflict_name);
276: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
277: exit;
270: n_dname := substrb('@'||l_dname, 1, 80);
271:
272: if ( n_dname = l_dname ) then
273: Wf_Core.Token('DNAME', x_display_name);
274: Wf_Core.Token('NAME', x_item_type||':'||x_name);
275: Wf_Core.Token('CONFLICT_NAME', conflict_name);
276: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
277: exit;
278: end if;
271:
272: if ( n_dname = l_dname ) then
273: Wf_Core.Token('DNAME', x_display_name);
274: Wf_Core.Token('NAME', x_item_type||':'||x_name);
275: Wf_Core.Token('CONFLICT_NAME', conflict_name);
276: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
277: exit;
278: end if;
279: exception
272: if ( n_dname = l_dname ) then
273: Wf_Core.Token('DNAME', x_display_name);
274: Wf_Core.Token('NAME', x_item_type||':'||x_name);
275: Wf_Core.Token('CONFLICT_NAME', conflict_name);
276: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
277: exit;
278: end if;
279: exception
280: when no_data_found then
291: -- and NAME = l_name
292: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
293: -- exception
294: -- when others then
295: -- Wf_Core.Token('TABLE', 'ITEM_ATTRIBUTES_TL');
296: -- Wf_Core.Token('VALUE', l_name);
297: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
298: -- end;
299: exception
292: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
293: -- exception
294: -- when others then
295: -- Wf_Core.Token('TABLE', 'ITEM_ATTRIBUTES_TL');
296: -- Wf_Core.Token('VALUE', l_name);
297: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
298: -- end;
299: exception
300: when no_data_found then
293: -- exception
294: -- when others then
295: -- Wf_Core.Token('TABLE', 'ITEM_ATTRIBUTES_TL');
296: -- Wf_Core.Token('VALUE', l_name);
297: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
298: -- end;
299: exception
300: when no_data_found then
301: null;
321: from WF_ITEM_ATTRIBUTES_VL
322: where ITEM_TYPE = x_item_type
323: and NAME = x_name;
324:
325: if ((wf_core.upload_mode <> 'FORCE') and
326: (protection_level < wf_core.session_level)) then
327: x_level_error := 1;
328: return;
329: end if;
322: where ITEM_TYPE = x_item_type
323: and NAME = x_name;
324:
325: if ((wf_core.upload_mode <> 'FORCE') and
326: (protection_level < wf_core.session_level)) then
327: x_level_error := 1;
328: return;
329: end if;
330:
327: x_level_error := 1;
328: return;
329: end if;
330:
331: if ((wf_core.upload_mode = 'UPGRADE') and
332: (customization_level > wf_core.session_level)) then
333: x_level_error := 2;
334: return;
335: end if;
328: return;
329: end if;
330:
331: if ((wf_core.upload_mode = 'UPGRADE') and
332: (customization_level > wf_core.session_level)) then
333: x_level_error := 2;
334: return;
335: end if;
336:
361: exception
362: when NO_DATA_FOUND then
363: -- Check protection level for new row
364: -- ### Relax the checking on attributes, lookup_code, transitions
365: if ((wf_core.upload_mode <> 'FORCE') and
366: (x_protect_level < wf_core.session_level)) then
367: x_level_error := 1;
368: return;
369: end if;
362: when NO_DATA_FOUND then
363: -- Check protection level for new row
364: -- ### Relax the checking on attributes, lookup_code, transitions
365: if ((wf_core.upload_mode <> 'FORCE') and
366: (x_protect_level < wf_core.session_level)) then
367: x_level_error := 1;
368: return;
369: end if;
370:
367: x_level_error := 1;
368: return;
369: end if;
370:
371: if ((wf_core.upload_mode = 'UPGRADE') and
372: (x_custom_level > wf_core.session_level)) then
373: x_level_error := 2;
374: return;
375: end if;
368: return;
369: end if;
370:
371: if ((wf_core.upload_mode = 'UPGRADE') and
372: (x_custom_level > wf_core.session_level)) then
373: x_level_error := 2;
374: return;
375: end if;
376:
408: end;
409:
410: exception
411: when OTHERS then
412: Wf_Core.Context('Wf_Load', 'Upload_Item_Attribute', x_item_type, x_name);
413: raise;
414: end UPLOAD_ITEM_ATTRIBUTE;
415:
416: --
462:
463: n_dname := substrb('@'||l_dname, 1, 80);
464:
465: if ( n_dname = l_dname ) then
466: Wf_Core.Token('DNAME', x_display_name);
467: Wf_Core.Token('NAME', x_lookup_type);
468: Wf_Core.Token('CONFLICT_NAME', conflict_name);
469: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
470: exit;
463: n_dname := substrb('@'||l_dname, 1, 80);
464:
465: if ( n_dname = l_dname ) then
466: Wf_Core.Token('DNAME', x_display_name);
467: Wf_Core.Token('NAME', x_lookup_type);
468: Wf_Core.Token('CONFLICT_NAME', conflict_name);
469: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
470: exit;
471: end if;
464:
465: if ( n_dname = l_dname ) then
466: Wf_Core.Token('DNAME', x_display_name);
467: Wf_Core.Token('NAME', x_lookup_type);
468: Wf_Core.Token('CONFLICT_NAME', conflict_name);
469: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
470: exit;
471: end if;
472: exception
465: if ( n_dname = l_dname ) then
466: Wf_Core.Token('DNAME', x_display_name);
467: Wf_Core.Token('NAME', x_lookup_type);
468: Wf_Core.Token('CONFLICT_NAME', conflict_name);
469: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
470: exit;
471: end if;
472: exception
473: when no_data_found then
482: -- where LOOKUP_TYPE = l_name
483: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
484: -- exception
485: -- when others then
486: -- Wf_Core.Token('TABLE', 'LOOKUP_TYPES_TL');
487: -- Wf_Core.Token('VALUE', l_name);
488: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
489: -- end;
490: exception
483: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
484: -- exception
485: -- when others then
486: -- Wf_Core.Token('TABLE', 'LOOKUP_TYPES_TL');
487: -- Wf_Core.Token('VALUE', l_name);
488: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
489: -- end;
490: exception
491: when no_data_found then
484: -- exception
485: -- when others then
486: -- Wf_Core.Token('TABLE', 'LOOKUP_TYPES_TL');
487: -- Wf_Core.Token('VALUE', l_name);
488: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
489: -- end;
490: exception
491: when no_data_found then
492: null;
499: into protection_level, customization_level
500: from WF_LOOKUP_TYPES
501: where LOOKUP_TYPE = x_lookup_type;
502:
503: if ((wf_core.upload_mode <> 'FORCE') and
504: (protection_level < wf_core.session_level)) then
505: x_level_error := 1;
506: return;
507: end if;
500: from WF_LOOKUP_TYPES
501: where LOOKUP_TYPE = x_lookup_type;
502:
503: if ((wf_core.upload_mode <> 'FORCE') and
504: (protection_level < wf_core.session_level)) then
505: x_level_error := 1;
506: return;
507: end if;
508:
505: x_level_error := 1;
506: return;
507: end if;
508:
509: if ((wf_core.upload_mode = 'UPGRADE') and
510: (customization_level > wf_core.session_level)) then
511: x_level_error := 2;
512: return;
513: end if;
506: return;
507: end if;
508:
509: if ((wf_core.upload_mode = 'UPGRADE') and
510: (customization_level > wf_core.session_level)) then
511: x_level_error := 2;
512: return;
513: end if;
514:
523: );
524: exception
525: when NO_DATA_FOUND then
526: -- Check protection level for new row
527: if ((wf_core.upload_mode <> 'FORCE') and
528: (x_protect_level < wf_core.session_level)) then
529: x_level_error := 4+1;
530: return;
531: end if;
524: exception
525: when NO_DATA_FOUND then
526: -- Check protection level for new row
527: if ((wf_core.upload_mode <> 'FORCE') and
528: (x_protect_level < wf_core.session_level)) then
529: x_level_error := 4+1;
530: return;
531: end if;
532:
529: x_level_error := 4+1;
530: return;
531: end if;
532:
533: if ((wf_core.upload_mode = 'UPGRADE') and
534: (x_custom_level > wf_core.session_level)) then
535: x_level_error := 4+2;
536: return;
537: end if;
530: return;
531: end if;
532:
533: if ((wf_core.upload_mode = 'UPGRADE') and
534: (x_custom_level > wf_core.session_level)) then
535: x_level_error := 4+2;
536: return;
537: end if;
538:
549: end;
550:
551: exception
552: when OTHERS then
553: Wf_Core.Context('Wf_Load', 'Upload_Lookup_Type', x_lookup_type);
554: raise;
555: end UPLOAD_LOOKUP_TYPE;
556:
557: --
604:
605: n_dname := substrb('@'||l_dname, 1, 80);
606:
607: if ( n_dname = l_dname ) then
608: Wf_Core.Token('DNAME', x_meaning);
609: Wf_Core.Token('NAME', x_lookup_code);
610: Wf_Core.Token('CONFLICT_NAME', conflict_name);
611: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
612: exit;
605: n_dname := substrb('@'||l_dname, 1, 80);
606:
607: if ( n_dname = l_dname ) then
608: Wf_Core.Token('DNAME', x_meaning);
609: Wf_Core.Token('NAME', x_lookup_code);
610: Wf_Core.Token('CONFLICT_NAME', conflict_name);
611: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
612: exit;
613: end if;
606:
607: if ( n_dname = l_dname ) then
608: Wf_Core.Token('DNAME', x_meaning);
609: Wf_Core.Token('NAME', x_lookup_code);
610: Wf_Core.Token('CONFLICT_NAME', conflict_name);
611: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
612: exit;
613: end if;
614: exception
607: if ( n_dname = l_dname ) then
608: Wf_Core.Token('DNAME', x_meaning);
609: Wf_Core.Token('NAME', x_lookup_code);
610: Wf_Core.Token('CONFLICT_NAME', conflict_name);
611: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
612: exit;
613: end if;
614: exception
615: when no_data_found then
626: -- and LOOKUP_CODE = l_name
627: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
628: -- exception
629: -- when others then
630: -- Wf_Core.Token('TABLE', 'LOOKUPS_TL');
631: -- Wf_Core.Token('VALUE', l_name);
632: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
633: -- end;
634: exception
627: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
628: -- exception
629: -- when others then
630: -- Wf_Core.Token('TABLE', 'LOOKUPS_TL');
631: -- Wf_Core.Token('VALUE', l_name);
632: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
633: -- end;
634: exception
635: when no_data_found then
628: -- exception
629: -- when others then
630: -- Wf_Core.Token('TABLE', 'LOOKUPS_TL');
631: -- Wf_Core.Token('VALUE', l_name);
632: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
633: -- end;
634: exception
635: when no_data_found then
636: null;
647: from WF_LOOKUPS
648: where LOOKUP_TYPE = x_lookup_type
649: and LOOKUP_CODE = x_lookup_code;
650:
651: if ((wf_core.upload_mode <> 'FORCE') and
652: (protection_level < wf_core.session_level)) then
653: x_level_error := 1;
654: return;
655: end if;
648: where LOOKUP_TYPE = x_lookup_type
649: and LOOKUP_CODE = x_lookup_code;
650:
651: if ((wf_core.upload_mode <> 'FORCE') and
652: (protection_level < wf_core.session_level)) then
653: x_level_error := 1;
654: return;
655: end if;
656:
653: x_level_error := 1;
654: return;
655: end if;
656:
657: if ((wf_core.upload_mode = 'UPGRADE') and
658: (customization_level > wf_core.session_level)) then
659: x_level_error := 2;
660: return;
661: end if;
654: return;
655: end if;
656:
657: if ((wf_core.upload_mode = 'UPGRADE') and
658: (customization_level > wf_core.session_level)) then
659: x_level_error := 2;
660: return;
661: end if;
662:
672: exception
673: when NO_DATA_FOUND then
674: -- Check protection level for new row
675: -- ### Relax the checking on attributes, lookup_code, transitions
676: if ((wf_core.upload_mode <> 'FORCE') and
677: (x_protect_level < wf_core.session_level)) then
678: x_level_error := 1;
679: return;
680: end if;
673: when NO_DATA_FOUND then
674: -- Check protection level for new row
675: -- ### Relax the checking on attributes, lookup_code, transitions
676: if ((wf_core.upload_mode <> 'FORCE') and
677: (x_protect_level < wf_core.session_level)) then
678: x_level_error := 1;
679: return;
680: end if;
681:
678: x_level_error := 1;
679: return;
680: end if;
681:
682: if ((wf_core.upload_mode = 'UPGRADE') and
683: (x_custom_level > wf_core.session_level)) then
684: x_level_error := 2;
685: return;
686: end if;
679: return;
680: end if;
681:
682: if ((wf_core.upload_mode = 'UPGRADE') and
683: (x_custom_level > wf_core.session_level)) then
684: x_level_error := 2;
685: return;
686: end if;
687:
698: end;
699:
700: exception
701: when OTHERS then
702: Wf_Core.Context('Wf_Load', 'Upload_Lookup', x_lookup_type, x_lookup_code);
703: raise;
704: end UPLOAD_LOOKUP;
705:
706: --
736: from WF_MESSAGES_VL
737: where TYPE = x_type
738: and NAME = x_name;
739:
740: if ((wf_core.upload_mode <> 'FORCE') and
741: (protection_level < wf_core.session_level)) then
742: x_level_error := 1;
743: return;
744: end if;
737: where TYPE = x_type
738: and NAME = x_name;
739:
740: if ((wf_core.upload_mode <> 'FORCE') and
741: (protection_level < wf_core.session_level)) then
742: x_level_error := 1;
743: return;
744: end if;
745:
742: x_level_error := 1;
743: return;
744: end if;
745:
746: if ((wf_core.upload_mode = 'UPGRADE') and
747: (customization_level > wf_core.session_level)) then
748: x_level_error := 2;
749: return;
750: end if;
743: return;
744: end if;
745:
746: if ((wf_core.upload_mode = 'UPGRADE') and
747: (customization_level > wf_core.session_level)) then
748: x_level_error := 2;
749: return;
750: end if;
751:
766: );
767: exception
768: when NO_DATA_FOUND then
769: -- Check protection level for new row
770: if ((wf_core.upload_mode <> 'FORCE') and
771: (x_protect_level < wf_core.session_level)) then
772: x_level_error := 4+1;
773: return;
774: end if;
767: exception
768: when NO_DATA_FOUND then
769: -- Check protection level for new row
770: if ((wf_core.upload_mode <> 'FORCE') and
771: (x_protect_level < wf_core.session_level)) then
772: x_level_error := 4+1;
773: return;
774: end if;
775:
772: x_level_error := 4+1;
773: return;
774: end if;
775:
776: if ((wf_core.upload_mode = 'UPGRADE') and
777: (x_custom_level > wf_core.session_level)) then
778: x_level_error := 4+2;
779: return;
780: end if;
773: return;
774: end if;
775:
776: if ((wf_core.upload_mode = 'UPGRADE') and
777: (x_custom_level > wf_core.session_level)) then
778: x_level_error := 4+2;
779: return;
780: end if;
781:
798: end;
799:
800: exception
801: when OTHERS then
802: Wf_Core.Context('Wf_Load', 'Upload_Message', x_type, x_name);
803: raise;
804: end UPLOAD_MESSAGE;
805:
806: --
856: and SEQUENCE = -1;
857:
858: exception
859: when others then
860: Wf_Core.Context('Wf_Load', 'Reseq_Message_Attribute', msgtype,
861: msgname, to_char(oldseq), to_char(newseq));
862: raise;
863: end Reseq_Message_Attribute;
864:
926:
927: n_dname := substrb('@'||l_dname, 1, 80);
928:
929: if ( n_dname = l_dname ) then
930: Wf_Core.Token('DNAME', x_display_name);
931: Wf_Core.Token('NAME', x_message_type||':'||x_message_name||':'
932: ||x_name);
933: Wf_Core.Token('CONFLICT_NAME', conflict_name);
934: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
927: n_dname := substrb('@'||l_dname, 1, 80);
928:
929: if ( n_dname = l_dname ) then
930: Wf_Core.Token('DNAME', x_display_name);
931: Wf_Core.Token('NAME', x_message_type||':'||x_message_name||':'
932: ||x_name);
933: Wf_Core.Token('CONFLICT_NAME', conflict_name);
934: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
935: exit;
929: if ( n_dname = l_dname ) then
930: Wf_Core.Token('DNAME', x_display_name);
931: Wf_Core.Token('NAME', x_message_type||':'||x_message_name||':'
932: ||x_name);
933: Wf_Core.Token('CONFLICT_NAME', conflict_name);
934: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
935: exit;
936: end if;
937: exception
930: Wf_Core.Token('DNAME', x_display_name);
931: Wf_Core.Token('NAME', x_message_type||':'||x_message_name||':'
932: ||x_name);
933: Wf_Core.Token('CONFLICT_NAME', conflict_name);
934: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
935: exit;
936: end if;
937: exception
938: when no_data_found then
950: -- and NAME = l_name
951: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
952: -- exception
953: -- when others then
954: -- Wf_Core.Token('TABLE', 'MESSAGE_ATTRIBUTES_TL');
955: -- Wf_Core.Token('VALUE', l_name);
956: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
957: -- end;
958: exception
951: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
952: -- exception
953: -- when others then
954: -- Wf_Core.Token('TABLE', 'MESSAGE_ATTRIBUTES_TL');
955: -- Wf_Core.Token('VALUE', l_name);
956: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
957: -- end;
958: exception
959: when no_data_found then
952: -- exception
953: -- when others then
954: -- Wf_Core.Token('TABLE', 'MESSAGE_ATTRIBUTES_TL');
955: -- Wf_Core.Token('VALUE', l_name);
956: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
957: -- end;
958: exception
959: when no_data_found then
960: null;
981: where MESSAGE_TYPE = x_message_type
982: and MESSAGE_NAME = x_message_name
983: and NAME = x_name;
984:
985: if ((wf_core.upload_mode <> 'FORCE') and
986: (protection_level < wf_core.session_level)) then
987: x_level_error := 1;
988: return;
989: end if;
982: and MESSAGE_NAME = x_message_name
983: and NAME = x_name;
984:
985: if ((wf_core.upload_mode <> 'FORCE') and
986: (protection_level < wf_core.session_level)) then
987: x_level_error := 1;
988: return;
989: end if;
990:
987: x_level_error := 1;
988: return;
989: end if;
990:
991: if ((wf_core.upload_mode = 'UPGRADE') and
992: (customization_level > wf_core.session_level)) then
993: x_level_error := 2;
994: return;
995: end if;
988: return;
989: end if;
990:
991: if ((wf_core.upload_mode = 'UPGRADE') and
992: (customization_level > wf_core.session_level)) then
993: x_level_error := 2;
994: return;
995: end if;
996:
1061: end;
1062:
1063: exception
1064: when OTHERS then
1065: Wf_Core.Context('Wf_Load', 'Upload_Message_Attribute', x_message_type,
1066: x_message_name, x_name);
1067: raise;
1068: end UPLOAD_MESSAGE_ATTRIBUTE;
1069:
1133: and x_effective_date >= BEGIN_DATE
1134: and x_effective_date < nvl(END_DATE, x_effective_date+1);
1135:
1136: if (x_type <> 'FOLDER') then
1137: if ((wf_core.upload_mode <> 'FORCE') and
1138: (protection_level < wf_core.session_level)) then
1139: x_level_error := 1;
1140: return;
1141: end if;
1134: and x_effective_date < nvl(END_DATE, x_effective_date+1);
1135:
1136: if (x_type <> 'FOLDER') then
1137: if ((wf_core.upload_mode <> 'FORCE') and
1138: (protection_level < wf_core.session_level)) then
1139: x_level_error := 1;
1140: return;
1141: end if;
1142:
1139: x_level_error := 1;
1140: return;
1141: end if;
1142:
1143: if ((wf_core.upload_mode = 'UPGRADE') and
1144: (customization_level > wf_core.session_level)) then
1145: x_level_error := 2;
1146: return;
1147: end if;
1140: return;
1141: end if;
1142:
1143: if ((wf_core.upload_mode = 'UPGRADE') and
1144: (customization_level > wf_core.session_level)) then
1145: x_level_error := 2;
1146: return;
1147: end if;
1148: end if;
1162: and BEGIN_DATE >= x_effective_date;
1163:
1164: -- Check protection level for new row
1165: if (x_type <> 'FOLDER') then
1166: if ((wf_core.upload_mode <> 'FORCE') and
1167: (x_protect_level < wf_core.session_level)) then
1168: x_level_error := 4+1;
1169: return;
1170: end if;
1163:
1164: -- Check protection level for new row
1165: if (x_type <> 'FOLDER') then
1166: if ((wf_core.upload_mode <> 'FORCE') and
1167: (x_protect_level < wf_core.session_level)) then
1168: x_level_error := 4+1;
1169: return;
1170: end if;
1171:
1168: x_level_error := 4+1;
1169: return;
1170: end if;
1171:
1172: if ((wf_core.upload_mode = 'UPGRADE') and
1173: (x_custom_level > wf_core.session_level)) then
1174: x_level_error := 4+2;
1175: return;
1176: end if;
1169: return;
1170: end if;
1171:
1172: if ((wf_core.upload_mode = 'UPGRADE') and
1173: (x_custom_level > wf_core.session_level)) then
1174: x_level_error := 4+2;
1175: return;
1176: end if;
1177: end if;
1242:
1243: n_dname := substrb('@'||l_dname, 1, 240);
1244:
1245: if ( n_dname = l_dname ) then
1246: Wf_Core.Token('DNAME', x_display_name);
1247: Wf_Core.Token('NAME', x_item_type||':'||x_name||':'||new_version);
1248: Wf_Core.Token('CONFLICT_NAME', conflict_name);
1249: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
1250: exit;
1243: n_dname := substrb('@'||l_dname, 1, 240);
1244:
1245: if ( n_dname = l_dname ) then
1246: Wf_Core.Token('DNAME', x_display_name);
1247: Wf_Core.Token('NAME', x_item_type||':'||x_name||':'||new_version);
1248: Wf_Core.Token('CONFLICT_NAME', conflict_name);
1249: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
1250: exit;
1251: end if;
1244:
1245: if ( n_dname = l_dname ) then
1246: Wf_Core.Token('DNAME', x_display_name);
1247: Wf_Core.Token('NAME', x_item_type||':'||x_name||':'||new_version);
1248: Wf_Core.Token('CONFLICT_NAME', conflict_name);
1249: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
1250: exit;
1251: end if;
1252: exception
1245: if ( n_dname = l_dname ) then
1246: Wf_Core.Token('DNAME', x_display_name);
1247: Wf_Core.Token('NAME', x_item_type||':'||x_name||':'||new_version);
1248: Wf_Core.Token('CONFLICT_NAME', conflict_name);
1249: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
1250: exit;
1251: end if;
1252: exception
1253: when no_data_found then
1265: -- and VERSION = new_version
1266: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
1267: -- exception
1268: -- when others then
1269: -- Wf_Core.Token('TABLE', 'ACTIVITIES_TL');
1270: -- Wf_Core.Token('VALUE', l_name);
1271: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
1272: -- end;
1273: exception
1266: -- and userenv('LANG') in (LANGUAGE, SOURCE_LANG);
1267: -- exception
1268: -- when others then
1269: -- Wf_Core.Token('TABLE', 'ACTIVITIES_TL');
1270: -- Wf_Core.Token('VALUE', l_name);
1271: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
1272: -- end;
1273: exception
1274: when no_data_found then
1267: -- exception
1268: -- when others then
1269: -- Wf_Core.Token('TABLE', 'ACTIVITIES_TL');
1270: -- Wf_Core.Token('VALUE', l_name);
1271: -- Wf_Core.Raise('WFSQL_UPDATE_FAIL');
1272: -- end;
1273: exception
1274: when no_data_found then
1275: null;
1417: /* ### Should not have a commit in this API */
1418: /* ### commit; */
1419: exception
1420: when OTHERS then
1421: Wf_Core.Context('Wf_Load', 'Upload_Activity', x_item_type, x_name);
1422: raise;
1423: end UPLOAD_ACTIVITY;
1424:
1425: --
1551: and SEQUENCE = -1;
1552:
1553: exception
1554: when others then
1555: Wf_Core.Context('Wf_Load', 'Reseq_Activity_Attribute', acttype,
1556: actname, to_char(actver), to_char(oldseq), to_char(newseq));
1557: raise;
1558: end Reseq_Activity_Attribute;
1559:
1607: and ACTIVITY_NAME = x_activity_name
1608: and ACTIVITY_VERSION = x_activity_version
1609: and NAME = x_name;
1610:
1611: if ((wf_core.upload_mode <> 'FORCE') and
1612: (protection_level < wf_core.session_level)) then
1613: x_level_error := 1;
1614: return;
1615: end if;
1608: and ACTIVITY_VERSION = x_activity_version
1609: and NAME = x_name;
1610:
1611: if ((wf_core.upload_mode <> 'FORCE') and
1612: (protection_level < wf_core.session_level)) then
1613: x_level_error := 1;
1614: return;
1615: end if;
1616:
1613: x_level_error := 1;
1614: return;
1615: end if;
1616:
1617: if ((wf_core.upload_mode = 'UPGRADE') and
1618: (customization_level > wf_core.session_level)) then
1619: x_level_error := 2;
1620: return;
1621: end if;
1614: return;
1615: end if;
1616:
1617: if ((wf_core.upload_mode = 'UPGRADE') and
1618: (customization_level > wf_core.session_level)) then
1619: x_level_error := 2;
1620: return;
1621: end if;
1622:
1652: exception
1653: when NO_DATA_FOUND then
1654: -- Check protection level for new row
1655: -- ### Relax the checking on attributes, lookup_code, transitions
1656: if ((wf_core.upload_mode <> 'FORCE') and
1657: (x_protect_level < wf_core.session_level)) then
1658: x_level_error := 1;
1659: return;
1660: end if;
1653: when NO_DATA_FOUND then
1654: -- Check protection level for new row
1655: -- ### Relax the checking on attributes, lookup_code, transitions
1656: if ((wf_core.upload_mode <> 'FORCE') and
1657: (x_protect_level < wf_core.session_level)) then
1658: x_level_error := 1;
1659: return;
1660: end if;
1661:
1658: x_level_error := 1;
1659: return;
1660: end if;
1661:
1662: if ((wf_core.upload_mode = 'UPGRADE') and
1663: (x_custom_level > wf_core.session_level)) then
1664: x_level_error := 2;
1665: return;
1666: end if;
1659: return;
1660: end if;
1661:
1662: if ((wf_core.upload_mode = 'UPGRADE') and
1663: (x_custom_level > wf_core.session_level)) then
1664: x_level_error := 2;
1665: return;
1666: end if;
1667:
1706: end;
1707:
1708: exception
1709: when OTHERS then
1710: Wf_Core.Context('Wf_Load', 'Upload_Activity_Attribute',
1711: x_activity_item_type, x_activity_name,
1712: to_char(x_activity_version), x_name);
1713: raise;
1714: end UPLOAD_ACTIVITY_ATTRIBUTE;
1767: from WF_PROCESS_ACTIVITIES
1768: where INSTANCE_ID = x_instance_id;
1769:
1770: if (x_process_name <> 'ROOT') then
1771: if ((wf_core.upload_mode <> 'FORCE') and
1772: (protection_level < wf_core.session_level)) then
1773: x_level_error := 1;
1774: return;
1775: end if;
1768: where INSTANCE_ID = x_instance_id;
1769:
1770: if (x_process_name <> 'ROOT') then
1771: if ((wf_core.upload_mode <> 'FORCE') and
1772: (protection_level < wf_core.session_level)) then
1773: x_level_error := 1;
1774: return;
1775: end if;
1776:
1773: x_level_error := 1;
1774: return;
1775: end if;
1776:
1777: if ((wf_core.upload_mode = 'UPGRADE') and
1778: (customization_level > wf_core.session_level)) then
1779: x_level_error := 2;
1780: return;
1781: end if;
1774: return;
1775: end if;
1776:
1777: if ((wf_core.upload_mode = 'UPGRADE') and
1778: (customization_level > wf_core.session_level)) then
1779: x_level_error := 2;
1780: return;
1781: end if;
1782: end if;
1826: where INSTANCE_ID = x_instance_id;
1827: exception
1828: when NO_DATA_FOUND then
1829: -- Check protection level for new row
1830: if ((wf_core.upload_mode <> 'FORCE') and
1831: (x_protect_level < wf_core.session_level)) then
1832: x_level_error := 4+1;
1833: return;
1834: end if;
1827: exception
1828: when NO_DATA_FOUND then
1829: -- Check protection level for new row
1830: if ((wf_core.upload_mode <> 'FORCE') and
1831: (x_protect_level < wf_core.session_level)) then
1832: x_level_error := 4+1;
1833: return;
1834: end if;
1835:
1832: x_level_error := 4+1;
1833: return;
1834: end if;
1835:
1836: if ((wf_core.upload_mode = 'UPGRADE') and
1837: (x_custom_level > wf_core.session_level)) then
1838: x_level_error := 4+2;
1839: return;
1840: end if;
1833: return;
1834: end if;
1835:
1836: if ((wf_core.upload_mode = 'UPGRADE') and
1837: (x_custom_level > wf_core.session_level)) then
1838: x_level_error := 4+2;
1839: return;
1840: end if;
1841:
1981: end;
1982:
1983: exception
1984: when OTHERS then
1985: Wf_Core.Context('Wf_Load', 'Upload_Process_Activity',x_process_name,
1986: x_activity_name,
1987: to_char(x_instance_id));
1988: raise;
1989: end UPLOAD_PROCESS_ACTIVITY;
2071: from WF_ACTIVITY_ATTR_VALUES
2072: where PROCESS_ACTIVITY_ID = x_process_activity_id
2073: and NAME = x_name;
2074:
2075: if ((wf_core.upload_mode <> 'FORCE') and
2076: (protection_level < wf_core.session_level)) then
2077: x_level_error := 1;
2078: return;
2079: end if;
2072: where PROCESS_ACTIVITY_ID = x_process_activity_id
2073: and NAME = x_name;
2074:
2075: if ((wf_core.upload_mode <> 'FORCE') and
2076: (protection_level < wf_core.session_level)) then
2077: x_level_error := 1;
2078: return;
2079: end if;
2080:
2077: x_level_error := 1;
2078: return;
2079: end if;
2080:
2081: if ((wf_core.upload_mode = 'UPGRADE') and
2082: (customization_level > wf_core.session_level)) then
2083: x_level_error := 2;
2084: return;
2085: end if;
2078: return;
2079: end if;
2080:
2081: if ((wf_core.upload_mode = 'UPGRADE') and
2082: (customization_level > wf_core.session_level)) then
2083: x_level_error := 2;
2084: return;
2085: end if;
2086:
2097: exception
2098: when NO_DATA_FOUND then
2099: -- Check protection level for new row
2100: -- ### Relax the checking on attributes, lookup_code, transitions
2101: if ((wf_core.upload_mode <> 'FORCE') and
2102: (x_protect_level < wf_core.session_level)) then
2103: x_level_error := 1;
2104: return;
2105: end if;
2098: when NO_DATA_FOUND then
2099: -- Check protection level for new row
2100: -- ### Relax the checking on attributes, lookup_code, transitions
2101: if ((wf_core.upload_mode <> 'FORCE') and
2102: (x_protect_level < wf_core.session_level)) then
2103: x_level_error := 1;
2104: return;
2105: end if;
2106:
2103: x_level_error := 1;
2104: return;
2105: end if;
2106:
2107: if ((wf_core.upload_mode = 'UPGRADE') and
2108: (x_custom_level > wf_core.session_level)) then
2109: x_level_error := 2;
2110: return;
2111: end if;
2104: return;
2105: end if;
2106:
2107: if ((wf_core.upload_mode = 'UPGRADE') and
2108: (x_custom_level > wf_core.session_level)) then
2109: x_level_error := 2;
2110: return;
2111: end if;
2112:
2133: end;
2134:
2135: exception
2136: when OTHERS then
2137: Wf_Core.Context('Wf_Load', 'Upload_Activity_Attr_Value',
2138: to_char(x_process_activity_id), x_name);
2139: raise;
2140: end UPLOAD_ACTIVITY_ATTR_VALUE;
2141:
2166: where FROM_PROCESS_ACTIVITY = x_from_process_activity
2167: and RESULT_CODE = x_result_code
2168: and TO_PROCESS_ACTIVITY = x_to_process_activity;
2169:
2170: if ((wf_core.upload_mode <> 'FORCE') and
2171: (protection_level < wf_core.session_level)) then
2172: x_level_error := 1;
2173: return;
2174: end if;
2167: and RESULT_CODE = x_result_code
2168: and TO_PROCESS_ACTIVITY = x_to_process_activity;
2169:
2170: if ((wf_core.upload_mode <> 'FORCE') and
2171: (protection_level < wf_core.session_level)) then
2172: x_level_error := 1;
2173: return;
2174: end if;
2175:
2172: x_level_error := 1;
2173: return;
2174: end if;
2175:
2176: if ((wf_core.upload_mode = 'UPGRADE') and
2177: (customization_level > wf_core.session_level)) then
2178: x_level_error := 2;
2179: return;
2180: end if;
2173: return;
2174: end if;
2175:
2176: if ((wf_core.upload_mode = 'UPGRADE') and
2177: (customization_level > wf_core.session_level)) then
2178: x_level_error := 2;
2179: return;
2180: end if;
2181:
2193: exception
2194: when NO_DATA_FOUND then
2195: -- Check protection level for new row
2196: -- ### Relax the checking on attributes, lookup_code, transitions
2197: if ((wf_core.upload_mode <> 'FORCE') and
2198: (x_protect_level < wf_core.session_level)) then
2199: x_level_error := 1;
2200: return;
2201: end if;
2194: when NO_DATA_FOUND then
2195: -- Check protection level for new row
2196: -- ### Relax the checking on attributes, lookup_code, transitions
2197: if ((wf_core.upload_mode <> 'FORCE') and
2198: (x_protect_level < wf_core.session_level)) then
2199: x_level_error := 1;
2200: return;
2201: end if;
2202:
2199: x_level_error := 1;
2200: return;
2201: end if;
2202:
2203: if ((wf_core.upload_mode = 'UPGRADE') and
2204: (x_custom_level > wf_core.session_level)) then
2205: x_level_error := 2;
2206: return;
2207: end if;
2200: return;
2201: end if;
2202:
2203: if ((wf_core.upload_mode = 'UPGRADE') and
2204: (x_custom_level > wf_core.session_level)) then
2205: x_level_error := 2;
2206: return;
2207: end if;
2208:
2225: end;
2226:
2227: exception
2228: when OTHERS then
2229: Wf_Core.Context('Wf_Load', 'Upload_Activity_Transition',
2230: to_char(x_from_process_activity),
2231: x_result_code,
2232: to_char(x_to_process_activity));
2233: raise;
2256: x_level_error);
2257:
2258: exception
2259: when others then
2260: Wf_Core.Context('Wf_Load', 'Upload_Resource', x_name, x_type);
2261: raise;
2262: end UPLOAD_RESOURCE;
2263:
2264: --
2280: into protection_level, customization_level
2281: from WF_LOOKUP_TYPES
2282: where LOOKUP_TYPE = x_lookup_type;
2283:
2284: if ((wf_core.upload_mode <> 'FORCE') and
2285: (protection_level < wf_core.session_level)) then
2286: x_level_error := 1;
2287: return;
2288: end if;
2281: from WF_LOOKUP_TYPES
2282: where LOOKUP_TYPE = x_lookup_type;
2283:
2284: if ((wf_core.upload_mode <> 'FORCE') and
2285: (protection_level < wf_core.session_level)) then
2286: x_level_error := 1;
2287: return;
2288: end if;
2289:
2286: x_level_error := 1;
2287: return;
2288: end if;
2289:
2290: if ((wf_core.upload_mode = 'UPGRADE') and
2291: (customization_level > wf_core.session_level)) then
2292: x_level_error := 2;
2293: return;
2294: end if;
2287: return;
2288: end if;
2289:
2290: if ((wf_core.upload_mode = 'UPGRADE') and
2291: (customization_level > wf_core.session_level)) then
2292: x_level_error := 2;
2293: return;
2294: end if;
2295:
2301: exception
2302: when NO_DATA_FOUND then
2303: null;
2304: when OTHERS then
2305: Wf_Core.Context('Wf_Load', 'Delete_Lookup_Type', x_lookup_type);
2306: raise;
2307: end DELETE_LOOKUP_TYPE;
2308:
2309: --
2327: from WF_LOOKUPS
2328: where LOOKUP_TYPE = x_lookup_type
2329: and LOOKUP_CODE = x_lookup_code;
2330:
2331: if ((wf_core.upload_mode <> 'FORCE') and
2332: (protection_level < wf_core.session_level)) then
2333: x_level_error := 1;
2334: return;
2335: end if;
2328: where LOOKUP_TYPE = x_lookup_type
2329: and LOOKUP_CODE = x_lookup_code;
2330:
2331: if ((wf_core.upload_mode <> 'FORCE') and
2332: (protection_level < wf_core.session_level)) then
2333: x_level_error := 1;
2334: return;
2335: end if;
2336:
2333: x_level_error := 1;
2334: return;
2335: end if;
2336:
2337: if ((wf_core.upload_mode = 'UPGRADE') and
2338: (customization_level > wf_core.session_level)) then
2339: x_level_error := 2;
2340: return;
2341: end if;
2334: return;
2335: end if;
2336:
2337: if ((wf_core.upload_mode = 'UPGRADE') and
2338: (customization_level > wf_core.session_level)) then
2339: x_level_error := 2;
2340: return;
2341: end if;
2342:
2348: exception
2349: when NO_DATA_FOUND then
2350: null;
2351: when OTHERS then
2352: Wf_Core.Context('Wf_Load', 'Delete_Lookup', x_lookup_type, x_lookup_code);
2353: raise;
2354: end DELETE_LOOKUP;
2355:
2356: --
2371: into protection_level, customization_level
2372: from WF_LOOKUP_TYPES_TL
2373: where LOOKUP_TYPE = X_LOOKUP_TYPE;
2374:
2375: if ((wf_core.upload_mode <> 'FORCE') and
2376: (protection_level < wf_core.session_level)) then
2377: x_level_error := 1;
2378: return;
2379: end if;
2372: from WF_LOOKUP_TYPES_TL
2373: where LOOKUP_TYPE = X_LOOKUP_TYPE;
2374:
2375: if ((wf_core.upload_mode <> 'FORCE') and
2376: (protection_level < wf_core.session_level)) then
2377: x_level_error := 1;
2378: return;
2379: end if;
2380:
2377: x_level_error := 1;
2378: return;
2379: end if;
2380:
2381: if ((wf_core.upload_mode = 'UPGRADE') and
2382: (customization_level > wf_core.session_level)) then
2383: x_level_error := 2;
2384: return;
2385: end if;
2378: return;
2379: end if;
2380:
2381: if ((wf_core.upload_mode = 'UPGRADE') and
2382: (customization_level > wf_core.session_level)) then
2383: x_level_error := 2;
2384: return;
2385: end if;
2386:
2390: exception
2391: when NO_DATA_FOUND then
2392: null;
2393: when OTHERS then
2394: wf_core.context('WF_LOAD', 'DELETE_LOOKUPS');
2395: raise;
2396: end DELETE_LOOKUPS;
2397:
2398: --
2420: into protection_level, customization_level, l_persistence_type
2421: from WF_ITEM_TYPES_VL
2422: where NAME = x_name;
2423:
2424: if ((wf_core.upload_mode <> 'FORCE') and
2425: (protection_level < wf_core.session_level)) then
2426: x_level_error := 1;
2427: return;
2428: end if;
2421: from WF_ITEM_TYPES_VL
2422: where NAME = x_name;
2423:
2424: if ((wf_core.upload_mode <> 'FORCE') and
2425: (protection_level < wf_core.session_level)) then
2426: x_level_error := 1;
2427: return;
2428: end if;
2429:
2426: x_level_error := 1;
2427: return;
2428: end if;
2429:
2430: if ((wf_core.upload_mode = 'UPGRADE') and
2431: (customization_level > wf_core.session_level)) then
2432: x_level_error := 2;
2433: return;
2434: end if;
2427: return;
2428: end if;
2429:
2430: if ((wf_core.upload_mode = 'UPGRADE') and
2431: (customization_level > wf_core.session_level)) then
2432: x_level_error := 2;
2433: return;
2434: end if;
2435:
2474: exception
2475: when NO_DATA_FOUND then
2476: null;
2477: when OTHERS then
2478: Wf_Core.Context('Wf_Load', 'Delete_Item_Type', x_name);
2479: raise;
2480: end DELETE_ITEM_TYPE;
2481:
2482: --
2500: from WF_ITEM_ATTRIBUTES_VL
2501: where ITEM_TYPE = x_item_type
2502: and NAME = x_name;
2503:
2504: if ((wf_core.upload_mode <> 'FORCE') and
2505: (protection_level < wf_core.session_level)) then
2506: x_level_error := 1;
2507: return;
2508: end if;
2501: where ITEM_TYPE = x_item_type
2502: and NAME = x_name;
2503:
2504: if ((wf_core.upload_mode <> 'FORCE') and
2505: (protection_level < wf_core.session_level)) then
2506: x_level_error := 1;
2507: return;
2508: end if;
2509:
2506: x_level_error := 1;
2507: return;
2508: end if;
2509:
2510: if ((wf_core.upload_mode = 'UPGRADE') and
2511: (customization_level > wf_core.session_level)) then
2512: x_level_error := 2;
2513: return;
2514: end if;
2507: return;
2508: end if;
2509:
2510: if ((wf_core.upload_mode = 'UPGRADE') and
2511: (customization_level > wf_core.session_level)) then
2512: x_level_error := 2;
2513: return;
2514: end if;
2515:
2520: exception
2521: when NO_DATA_FOUND then
2522: null;
2523: when OTHERS then
2524: Wf_Core.Context('Wf_Load', 'Delete_Item_Attribute', x_item_type, x_name);
2525: raise;
2526: end DELETE_ITEM_ATTRIBUTE;
2527:
2528: --
2544: into protection_level, customization_level
2545: from WF_ITEM_TYPES_VL
2546: where NAME = x_item_type;
2547:
2548: if ((wf_core.upload_mode <> 'FORCE') and
2549: (protection_level < wf_core.session_level)) then
2550: x_level_error := 1;
2551: return;
2552: end if;
2545: from WF_ITEM_TYPES_VL
2546: where NAME = x_item_type;
2547:
2548: if ((wf_core.upload_mode <> 'FORCE') and
2549: (protection_level < wf_core.session_level)) then
2550: x_level_error := 1;
2551: return;
2552: end if;
2553:
2550: x_level_error := 1;
2551: return;
2552: end if;
2553:
2554: if ((wf_core.upload_mode = 'UPGRADE') and
2555: (customization_level > wf_core.session_level)) then
2556: x_level_error := 2;
2557: return;
2558: end if;
2551: return;
2552: end if;
2553:
2554: if ((wf_core.upload_mode = 'UPGRADE') and
2555: (customization_level > wf_core.session_level)) then
2556: x_level_error := 2;
2557: return;
2558: end if;
2559:
2565: exception
2566: when NO_DATA_FOUND then
2567: null;
2568: when OTHERS then
2569: Wf_Core.Context('Wf_Load', 'Delete_Item_Attributes', x_item_type);
2570: raise;
2571: end DELETE_ITEM_ATTRIBUTES;
2572:
2573: --
2596: from WF_MESSAGES
2597: where TYPE = x_type
2598: and NAME = x_name;
2599:
2600: if ((wf_core.upload_mode <> 'FORCE') and
2601: (protection_level < wf_core.session_level)) then
2602: x_level_error := 1;
2603: return;
2604: end if;
2597: where TYPE = x_type
2598: and NAME = x_name;
2599:
2600: if ((wf_core.upload_mode <> 'FORCE') and
2601: (protection_level < wf_core.session_level)) then
2602: x_level_error := 1;
2603: return;
2604: end if;
2605:
2602: x_level_error := 1;
2603: return;
2604: end if;
2605:
2606: if ((wf_core.upload_mode = 'UPGRADE') and
2607: (customization_level > wf_core.session_level)) then
2608: x_level_error := 2;
2609: return;
2610: end if;
2603: return;
2604: end if;
2605:
2606: if ((wf_core.upload_mode = 'UPGRADE') and
2607: (customization_level > wf_core.session_level)) then
2608: x_level_error := 2;
2609: return;
2610: end if;
2611:
2639: exception
2640: when NO_DATA_FOUND then
2641: null;
2642: when OTHERS then
2643: Wf_Core.Context('Wf_Load', 'Delete_Message', x_type, x_name);
2644: raise;
2645: end DELETE_MESSAGE;
2646:
2647: --
2665: where MESSAGE_TYPE = x_message_type
2666: and MESSAGE_NAME = x_message_name
2667: and NAME = x_name;
2668:
2669: if ((wf_core.upload_mode <> 'FORCE') and
2670: (protection_level < wf_core.session_level)) then
2671: x_level_error := 1;
2672: return;
2673: end if;
2666: and MESSAGE_NAME = x_message_name
2667: and NAME = x_name;
2668:
2669: if ((wf_core.upload_mode <> 'FORCE') and
2670: (protection_level < wf_core.session_level)) then
2671: x_level_error := 1;
2672: return;
2673: end if;
2674:
2671: x_level_error := 1;
2672: return;
2673: end if;
2674:
2675: if ((wf_core.upload_mode = 'UPGRADE') and
2676: (customization_level > wf_core.session_level)) then
2677: x_level_error := 2;
2678: return;
2679: end if;
2672: return;
2673: end if;
2674:
2675: if ((wf_core.upload_mode = 'UPGRADE') and
2676: (customization_level > wf_core.session_level)) then
2677: x_level_error := 2;
2678: return;
2679: end if;
2680:
2686: exception
2687: when NO_DATA_FOUND then
2688: null;
2689: when OTHERS then
2690: Wf_Core.Context('Wf_Load', 'Delete_Message_Attribute', x_message_type,
2691: x_message_name, x_name);
2692: raise;
2693: end DELETE_MESSAGE_ATTRIBUTE;
2694:
2713: from WF_MESSAGES
2714: where TYPE = x_message_type
2715: and NAME = x_message_name;
2716:
2717: if ((wf_core.upload_mode <> 'FORCE') and
2718: (protection_level < wf_core.session_level)) then
2719: x_level_error := 1;
2720: return;
2721: end if;
2714: where TYPE = x_message_type
2715: and NAME = x_message_name;
2716:
2717: if ((wf_core.upload_mode <> 'FORCE') and
2718: (protection_level < wf_core.session_level)) then
2719: x_level_error := 1;
2720: return;
2721: end if;
2722:
2719: x_level_error := 1;
2720: return;
2721: end if;
2722:
2723: if ((wf_core.upload_mode = 'UPGRADE') and
2724: (customization_level > wf_core.session_level)) then
2725: x_level_error := 2;
2726: return;
2727: end if;
2720: return;
2721: end if;
2722:
2723: if ((wf_core.upload_mode = 'UPGRADE') and
2724: (customization_level > wf_core.session_level)) then
2725: x_level_error := 2;
2726: return;
2727: end if;
2728:
2737: exception
2738: when NO_DATA_FOUND then
2739: null;
2740: when OTHERS then
2741: Wf_Core.Context('Wf_Load', 'Delete_Message_Attributes', x_message_type,
2742: x_message_name);
2743: raise;
2744: end DELETE_MESSAGE_ATTRIBUTES;
2745:
2767: where ITEM_TYPE = x_item_type
2768: and NAME = x_name
2769: and END_DATE is null;
2770:
2771: if ((wf_core.upload_mode <> 'FORCE') and
2772: (protection_level < wf_core.session_level)) then
2773: x_level_error := 1;
2774: return;
2775: end if;
2768: and NAME = x_name
2769: and END_DATE is null;
2770:
2771: if ((wf_core.upload_mode <> 'FORCE') and
2772: (protection_level < wf_core.session_level)) then
2773: x_level_error := 1;
2774: return;
2775: end if;
2776:
2773: x_level_error := 1;
2774: return;
2775: end if;
2776:
2777: if ((wf_core.upload_mode = 'UPGRADE') and
2778: (customization_level > wf_core.session_level)) then
2779: x_level_error := 2;
2780: return;
2781: end if;
2774: return;
2775: end if;
2776:
2777: if ((wf_core.upload_mode = 'UPGRADE') and
2778: (customization_level > wf_core.session_level)) then
2779: x_level_error := 2;
2780: return;
2781: end if;
2782:
2803: exception
2804: when NO_DATA_FOUND then
2805: null;
2806: when OTHERS then
2807: Wf_Core.Context('Wf_Load', 'Delete_Activity', x_item_type, x_name);
2808: raise;
2809: end DELETE_ACTIVITY;
2810:
2811: --
2855: end if;
2856: end if;
2857: exception
2858: when OTHERS then
2859: Wf_Core.Context('Wf_Load', 'Delete_Transition', p_previous_step,
2860: p_next_step, p_result_code);
2861: raise;
2862: end;
2863:
2894: p_ycor := to_number(substr(l_icon_geometry, comma_position + 1));
2895:
2896: exception
2897: when OTHERS then
2898: Wf_Core.Context('Wf_Load', 'Get_Process_Activity', p_activity_instance);
2899: raise;
2900: end;
2901:
2902: --
2966: x_level_error => p_level_error);
2967:
2968: exception
2969: when OTHERS then
2970: Wf_Core.Context('Wf_Load', 'Get_Message', p_type, p_name);
2971: raise;
2972: end;
2973:
2974: --
3022: and NAME = p_name;
3023:
3024: exception
3025: when OTHERS then
3026: Wf_Core.Context('Wf_Load', 'Get_Message', p_type, p_name);
3027: raise;
3028: end;
3029:
3030: --
3201: from WF_ITEM_TYPES_VL
3202: where NAME = p_item_type;
3203: exception
3204: when others then
3205: Wf_Core.Context('Wf_Load', 'Selecting ITEM_TYPE', p_item_type);
3206: raise;
3207: end;
3208:
3209: begin
3235: );
3236: l_dname := null;
3237:
3238: if (l_level_error <> 0) then
3239: Wf_Core.Token('ENTITY', 'ITEM_TYPE');
3240: Wf_Core.Token('TYPE', '');
3241: Wf_Core.Token('NAME', p_destination_item_type);
3242: Wf_Core.Raise('WFLDRSD_UPI');
3243: end if;
3236: l_dname := null;
3237:
3238: if (l_level_error <> 0) then
3239: Wf_Core.Token('ENTITY', 'ITEM_TYPE');
3240: Wf_Core.Token('TYPE', '');
3241: Wf_Core.Token('NAME', p_destination_item_type);
3242: Wf_Core.Raise('WFLDRSD_UPI');
3243: end if;
3244:
3237:
3238: if (l_level_error <> 0) then
3239: Wf_Core.Token('ENTITY', 'ITEM_TYPE');
3240: Wf_Core.Token('TYPE', '');
3241: Wf_Core.Token('NAME', p_destination_item_type);
3242: Wf_Core.Raise('WFLDRSD_UPI');
3243: end if;
3244:
3245:
3238: if (l_level_error <> 0) then
3239: Wf_Core.Token('ENTITY', 'ITEM_TYPE');
3240: Wf_Core.Token('TYPE', '');
3241: Wf_Core.Token('NAME', p_destination_item_type);
3242: Wf_Core.Raise('WFLDRSD_UPI');
3243: end if;
3244:
3245:
3246: -- Copy Lookup Types
3256: x_item_type=>p_destination_item_type,
3257: x_level_error=>l_level_error
3258: );
3259: if (l_level_error <> 0) then
3260: Wf_Core.Token('ENTITY', 'LOOKUP_TYPE');
3261: Wf_Core.Token('TYPE', p_destination_item_type);
3262: Wf_Core.Token('NAME', substr(lutr.lookup_type||p_new_suffix, 1, 30));
3263: Wf_Core.Raise('WFLDRSD_UPI');
3264: end if;
3257: x_level_error=>l_level_error
3258: );
3259: if (l_level_error <> 0) then
3260: Wf_Core.Token('ENTITY', 'LOOKUP_TYPE');
3261: Wf_Core.Token('TYPE', p_destination_item_type);
3262: Wf_Core.Token('NAME', substr(lutr.lookup_type||p_new_suffix, 1, 30));
3263: Wf_Core.Raise('WFLDRSD_UPI');
3264: end if;
3265: i := i + 1;
3258: );
3259: if (l_level_error <> 0) then
3260: Wf_Core.Token('ENTITY', 'LOOKUP_TYPE');
3261: Wf_Core.Token('TYPE', p_destination_item_type);
3262: Wf_Core.Token('NAME', substr(lutr.lookup_type||p_new_suffix, 1, 30));
3263: Wf_Core.Raise('WFLDRSD_UPI');
3264: end if;
3265: i := i + 1;
3266: end loop;
3259: if (l_level_error <> 0) then
3260: Wf_Core.Token('ENTITY', 'LOOKUP_TYPE');
3261: Wf_Core.Token('TYPE', p_destination_item_type);
3262: Wf_Core.Token('NAME', substr(lutr.lookup_type||p_new_suffix, 1, 30));
3263: Wf_Core.Raise('WFLDRSD_UPI');
3264: end if;
3265: i := i + 1;
3266: end loop;
3267:
3277: x_custom_level=>lucr.custom_level,
3278: x_level_error=>l_level_error
3279: );
3280: if (l_level_error <> 0) then
3281: Wf_Core.Token('ENTITY', 'LOOKUP_CODE');
3282: Wf_Core.Token('TYPE', substr(v_lut(j)||p_new_suffix, 1, 30));
3283: Wf_Core.Token('NAME', lucr.lookup_code);
3284: Wf_Core.Raise('WFLDRSD_UPI');
3285: end if;
3278: x_level_error=>l_level_error
3279: );
3280: if (l_level_error <> 0) then
3281: Wf_Core.Token('ENTITY', 'LOOKUP_CODE');
3282: Wf_Core.Token('TYPE', substr(v_lut(j)||p_new_suffix, 1, 30));
3283: Wf_Core.Token('NAME', lucr.lookup_code);
3284: Wf_Core.Raise('WFLDRSD_UPI');
3285: end if;
3286: end loop;
3279: );
3280: if (l_level_error <> 0) then
3281: Wf_Core.Token('ENTITY', 'LOOKUP_CODE');
3282: Wf_Core.Token('TYPE', substr(v_lut(j)||p_new_suffix, 1, 30));
3283: Wf_Core.Token('NAME', lucr.lookup_code);
3284: Wf_Core.Raise('WFLDRSD_UPI');
3285: end if;
3286: end loop;
3287: end loop;
3280: if (l_level_error <> 0) then
3281: Wf_Core.Token('ENTITY', 'LOOKUP_CODE');
3282: Wf_Core.Token('TYPE', substr(v_lut(j)||p_new_suffix, 1, 30));
3283: Wf_Core.Token('NAME', lucr.lookup_code);
3284: Wf_Core.Raise('WFLDRSD_UPI');
3285: end if;
3286: end loop;
3287: end loop;
3288:
3318: x_default=>l_default,
3319: x_level_error=>l_level_error
3320: );
3321: if (l_level_error <> 0) then
3322: Wf_Core.Token('ENTITY', 'ITEM_ATTRIBUTE');
3323: Wf_Core.Token('TYPE', p_destination_item_type);
3324: Wf_Core.Token('NAME', itar.name);
3325: Wf_Core.Raise('WFLDRSD_UPI');
3326: end if;
3319: x_level_error=>l_level_error
3320: );
3321: if (l_level_error <> 0) then
3322: Wf_Core.Token('ENTITY', 'ITEM_ATTRIBUTE');
3323: Wf_Core.Token('TYPE', p_destination_item_type);
3324: Wf_Core.Token('NAME', itar.name);
3325: Wf_Core.Raise('WFLDRSD_UPI');
3326: end if;
3327: end loop;
3320: );
3321: if (l_level_error <> 0) then
3322: Wf_Core.Token('ENTITY', 'ITEM_ATTRIBUTE');
3323: Wf_Core.Token('TYPE', p_destination_item_type);
3324: Wf_Core.Token('NAME', itar.name);
3325: Wf_Core.Raise('WFLDRSD_UPI');
3326: end if;
3327: end loop;
3328:
3321: if (l_level_error <> 0) then
3322: Wf_Core.Token('ENTITY', 'ITEM_ATTRIBUTE');
3323: Wf_Core.Token('TYPE', p_destination_item_type);
3324: Wf_Core.Token('NAME', itar.name);
3325: Wf_Core.Raise('WFLDRSD_UPI');
3326: end if;
3327: end loop;
3328:
3329: -- Copy Message
3345: x_write_role=>msgr.write_role,
3346: x_level_error=>l_level_error
3347: );
3348: if (l_level_error <> 0) then
3349: Wf_Core.Token('ENTITY', 'MESSAGE');
3350: Wf_Core.Token('TYPE', p_destination_item_type);
3351: Wf_Core.Token('NAME', msgr.name);
3352: Wf_Core.Raise('WFLDRSD_UPI');
3353: end if;
3346: x_level_error=>l_level_error
3347: );
3348: if (l_level_error <> 0) then
3349: Wf_Core.Token('ENTITY', 'MESSAGE');
3350: Wf_Core.Token('TYPE', p_destination_item_type);
3351: Wf_Core.Token('NAME', msgr.name);
3352: Wf_Core.Raise('WFLDRSD_UPI');
3353: end if;
3354: i := i + 1;
3347: );
3348: if (l_level_error <> 0) then
3349: Wf_Core.Token('ENTITY', 'MESSAGE');
3350: Wf_Core.Token('TYPE', p_destination_item_type);
3351: Wf_Core.Token('NAME', msgr.name);
3352: Wf_Core.Raise('WFLDRSD_UPI');
3353: end if;
3354: i := i + 1;
3355: end loop;
3348: if (l_level_error <> 0) then
3349: Wf_Core.Token('ENTITY', 'MESSAGE');
3350: Wf_Core.Token('TYPE', p_destination_item_type);
3351: Wf_Core.Token('NAME', msgr.name);
3352: Wf_Core.Raise('WFLDRSD_UPI');
3353: end if;
3354: i := i + 1;
3355: end loop;
3356:
3400: x_attach=>msar.attach,
3401: x_level_error=>l_level_error
3402: );
3403: if (l_level_error <> 0) then
3404: Wf_Core.Token('ENTITY', 'MESSAGE_ATTRIBUTE');
3405: Wf_Core.Token('TYPE', v_msg(j));
3406: Wf_Core.Token('NAME', msar.name);
3407: Wf_Core.Raise('WFLDRSD_UPI');
3408: end if;
3401: x_level_error=>l_level_error
3402: );
3403: if (l_level_error <> 0) then
3404: Wf_Core.Token('ENTITY', 'MESSAGE_ATTRIBUTE');
3405: Wf_Core.Token('TYPE', v_msg(j));
3406: Wf_Core.Token('NAME', msar.name);
3407: Wf_Core.Raise('WFLDRSD_UPI');
3408: end if;
3409: end loop;
3402: );
3403: if (l_level_error <> 0) then
3404: Wf_Core.Token('ENTITY', 'MESSAGE_ATTRIBUTE');
3405: Wf_Core.Token('TYPE', v_msg(j));
3406: Wf_Core.Token('NAME', msar.name);
3407: Wf_Core.Raise('WFLDRSD_UPI');
3408: end if;
3409: end loop;
3410: end loop;
3403: if (l_level_error <> 0) then
3404: Wf_Core.Token('ENTITY', 'MESSAGE_ATTRIBUTE');
3405: Wf_Core.Token('TYPE', v_msg(j));
3406: Wf_Core.Token('NAME', msar.name);
3407: Wf_Core.Raise('WFLDRSD_UPI');
3408: end if;
3409: end loop;
3410: end loop;
3411:
3465: x_version=>l_version,
3466: x_level_error=>l_level_error
3467: );
3468: if (l_level_error <> 0) then
3469: Wf_Core.Token('ENTITY', 'ACTIVITY');
3470: Wf_Core.Token('TYPE', p_destination_item_type);
3471: Wf_Core.Token('NAME', actr.name);
3472: Wf_Core.Raise('WFLDRSD_UPI');
3473: end if;
3466: x_level_error=>l_level_error
3467: );
3468: if (l_level_error <> 0) then
3469: Wf_Core.Token('ENTITY', 'ACTIVITY');
3470: Wf_Core.Token('TYPE', p_destination_item_type);
3471: Wf_Core.Token('NAME', actr.name);
3472: Wf_Core.Raise('WFLDRSD_UPI');
3473: end if;
3474: i := i + 1;
3467: );
3468: if (l_level_error <> 0) then
3469: Wf_Core.Token('ENTITY', 'ACTIVITY');
3470: Wf_Core.Token('TYPE', p_destination_item_type);
3471: Wf_Core.Token('NAME', actr.name);
3472: Wf_Core.Raise('WFLDRSD_UPI');
3473: end if;
3474: i := i + 1;
3475: end loop;
3468: if (l_level_error <> 0) then
3469: Wf_Core.Token('ENTITY', 'ACTIVITY');
3470: Wf_Core.Token('TYPE', p_destination_item_type);
3471: Wf_Core.Token('NAME', actr.name);
3472: Wf_Core.Raise('WFLDRSD_UPI');
3473: end if;
3474: i := i + 1;
3475: end loop;
3476:
3515: x_value_type=>atar.value_type,
3516: x_level_error=>l_level_error
3517: );
3518: if (l_level_error <> 0) then
3519: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTRIBUTE');
3520: Wf_Core.Token('TYPE', substr(v_act(j).name,1,30));
3521: Wf_Core.Token('NAME', atar.name);
3522: Wf_Core.Raise('WFLDRSD_UPI');
3523: end if;
3516: x_level_error=>l_level_error
3517: );
3518: if (l_level_error <> 0) then
3519: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTRIBUTE');
3520: Wf_Core.Token('TYPE', substr(v_act(j).name,1,30));
3521: Wf_Core.Token('NAME', atar.name);
3522: Wf_Core.Raise('WFLDRSD_UPI');
3523: end if;
3524: end loop;
3517: );
3518: if (l_level_error <> 0) then
3519: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTRIBUTE');
3520: Wf_Core.Token('TYPE', substr(v_act(j).name,1,30));
3521: Wf_Core.Token('NAME', atar.name);
3522: Wf_Core.Raise('WFLDRSD_UPI');
3523: end if;
3524: end loop;
3525: end loop;
3518: if (l_level_error <> 0) then
3519: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTRIBUTE');
3520: Wf_Core.Token('TYPE', substr(v_act(j).name,1,30));
3521: Wf_Core.Token('NAME', atar.name);
3522: Wf_Core.Raise('WFLDRSD_UPI');
3523: end if;
3524: end loop;
3525: end loop;
3526:
3581: x_user_comment=>pacr.user_comment,
3582: x_level_error=>l_level_error
3583: );
3584: if (l_level_error <> 0) then
3585: Wf_Core.Token('ENTITY', 'PROCESS_ACTIVITY');
3586: Wf_Core.Token('TYPE', v_act(j).name);
3587: Wf_Core.Token('NAME', pacr.activity_name);
3588: Wf_Core.Raise('WFLDRSD_UPI');
3589: end if;
3582: x_level_error=>l_level_error
3583: );
3584: if (l_level_error <> 0) then
3585: Wf_Core.Token('ENTITY', 'PROCESS_ACTIVITY');
3586: Wf_Core.Token('TYPE', v_act(j).name);
3587: Wf_Core.Token('NAME', pacr.activity_name);
3588: Wf_Core.Raise('WFLDRSD_UPI');
3589: end if;
3590: end;
3583: );
3584: if (l_level_error <> 0) then
3585: Wf_Core.Token('ENTITY', 'PROCESS_ACTIVITY');
3586: Wf_Core.Token('TYPE', v_act(j).name);
3587: Wf_Core.Token('NAME', pacr.activity_name);
3588: Wf_Core.Raise('WFLDRSD_UPI');
3589: end if;
3590: end;
3591: i := i + 1;
3584: if (l_level_error <> 0) then
3585: Wf_Core.Token('ENTITY', 'PROCESS_ACTIVITY');
3586: Wf_Core.Token('TYPE', v_act(j).name);
3587: Wf_Core.Token('NAME', pacr.activity_name);
3588: Wf_Core.Raise('WFLDRSD_UPI');
3589: end if;
3590: end;
3591: i := i + 1;
3592: end loop;
3621: x_arrow_geometry=>patr.arrow_geometry,
3622: x_level_error=>l_level_error
3623: );
3624: if (l_level_error <> 0) then
3625: Wf_Core.Token('ENTITY', 'ACTIVITY_TRANSITION');
3626: Wf_Core.Token('TYPE', '');
3627: Wf_Core.Token('NAME', to_char(v_npac(j))||'-'||to_char(v_npac(toid)));
3628: Wf_Core.Raise('WFLDRSD_UPI');
3629: end if;
3622: x_level_error=>l_level_error
3623: );
3624: if (l_level_error <> 0) then
3625: Wf_Core.Token('ENTITY', 'ACTIVITY_TRANSITION');
3626: Wf_Core.Token('TYPE', '');
3627: Wf_Core.Token('NAME', to_char(v_npac(j))||'-'||to_char(v_npac(toid)));
3628: Wf_Core.Raise('WFLDRSD_UPI');
3629: end if;
3630: end loop;
3623: );
3624: if (l_level_error <> 0) then
3625: Wf_Core.Token('ENTITY', 'ACTIVITY_TRANSITION');
3626: Wf_Core.Token('TYPE', '');
3627: Wf_Core.Token('NAME', to_char(v_npac(j))||'-'||to_char(v_npac(toid)));
3628: Wf_Core.Raise('WFLDRSD_UPI');
3629: end if;
3630: end loop;
3631:
3624: if (l_level_error <> 0) then
3625: Wf_Core.Token('ENTITY', 'ACTIVITY_TRANSITION');
3626: Wf_Core.Token('TYPE', '');
3627: Wf_Core.Token('NAME', to_char(v_npac(j))||'-'||to_char(v_npac(toid)));
3628: Wf_Core.Raise('WFLDRSD_UPI');
3629: end if;
3630: end loop;
3631:
3632: -- Copy Activity Attr Values
3651: x_effective_date=>sysdate,
3652: x_level_error=>l_level_error
3653: );
3654: if (l_level_error <> 0) then
3655: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTR_VALUE');
3656: Wf_Core.Token('TYPE', to_char(v_npac(j)));
3657: Wf_Core.Token('NAME', aavr.name);
3658: Wf_Core.Raise('WFLDRSD_UPI');
3659: end if;
3652: x_level_error=>l_level_error
3653: );
3654: if (l_level_error <> 0) then
3655: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTR_VALUE');
3656: Wf_Core.Token('TYPE', to_char(v_npac(j)));
3657: Wf_Core.Token('NAME', aavr.name);
3658: Wf_Core.Raise('WFLDRSD_UPI');
3659: end if;
3660: end loop;
3653: );
3654: if (l_level_error <> 0) then
3655: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTR_VALUE');
3656: Wf_Core.Token('TYPE', to_char(v_npac(j)));
3657: Wf_Core.Token('NAME', aavr.name);
3658: Wf_Core.Raise('WFLDRSD_UPI');
3659: end if;
3660: end loop;
3661: end loop;
3654: if (l_level_error <> 0) then
3655: Wf_Core.Token('ENTITY', 'ACTIVITY_ATTR_VALUE');
3656: Wf_Core.Token('TYPE', to_char(v_npac(j)));
3657: Wf_Core.Token('NAME', aavr.name);
3658: Wf_Core.Raise('WFLDRSD_UPI');
3659: end if;
3660: end loop;
3661: end loop;
3662:
3676: end if;
3677: if (msacur%isopen) then
3678: close msacur;
3679: end if;
3680: Wf_Core.Context('Wf_Load', 'COPY_ITEM_TYPE', p_item_type,
3681: p_destination_item_type,
3682: p_new_suffix);
3683: raise;
3684: end;
3729: delete from WF_PROCESS_ACTIVITIES where INSTANCE_ID = p_step;
3730:
3731: exception
3732: when OTHERS then
3733: Wf_Core.Context('Wf_Load', 'Delete_Process_Activity',
3734: to_char(p_step));
3735: raise;
3736: end;
3737:
3760: where PROCESS_ACTIVITY_ID = p_process_instance_id
3761: and NAME = p_attribute_name;
3762: exception
3763: when OTHERS then
3764: Wf_Core.Context('Wf_Load', 'Get_Activity_Attr_Val',
3765: to_char(p_process_instance_id), p_attribute_name);
3766: raise;
3767: end;
3768:
3804: end if;
3805:
3806: exception
3807: when OTHERS then
3808: Wf_Core.Context('Wf_Load', 'Get_Item_Attribute',
3809: p_item_type, p_attribute_name);
3810: raise;
3811: end;
3812:
3911: and NAME = p_name
3912: and END_DATE is null;
3913: exception
3914: when OTHERS then
3915: Wf_Core.Context('Wf_Load', 'Get_Activity', p_item_type, p_name);
3916: raise;
3917: end;
3918:
3919: --
3994: p_version=>l_version
3995: );
3996: -- Check protect and custom level
3997: if (l_type <> 'FOLDER') then
3998: if ((wf_core.upload_mode <> 'FORCE') and
3999: (l_protect_level < wf_core.session_level)) then
4000: p_level_error := 1;
4001: return;
4002: end if;
3995: );
3996: -- Check protect and custom level
3997: if (l_type <> 'FOLDER') then
3998: if ((wf_core.upload_mode <> 'FORCE') and
3999: (l_protect_level < wf_core.session_level)) then
4000: p_level_error := 1;
4001: return;
4002: end if;
4003:
4000: p_level_error := 1;
4001: return;
4002: end if;
4003:
4004: if ((wf_core.upload_mode = 'UPGRADE') and
4005: (l_custom_level > wf_core.session_level)) then
4006: p_level_error := 2;
4007: return;
4008: end if;
4001: return;
4002: end if;
4003:
4004: if ((wf_core.upload_mode = 'UPGRADE') and
4005: (l_custom_level > wf_core.session_level)) then
4006: p_level_error := 2;
4007: return;
4008: end if;
4009: end if;
4009: end if;
4010: exception
4011: when OTHERS then
4012: -- Don't proceed
4013: Wf_Core.Context('Wf_Load', 'Update_Activity Get_Activity');
4014: raise;
4015: end;
4016:
4017: if (p_display_name is not null) then
4056:
4057: n_dname := substrb('@'||l_dname, 1, 80);
4058:
4059: if ( n_dname = l_dname ) then
4060: Wf_Core.Token('DNAME', l_display_name);
4061: Wf_Core.Token('NAME', p_item_type||':'||p_name||':'||
4062: to_char(l_version));
4063: Wf_Core.Token('CONFLICT_NAME', conflict_name);
4064: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
4057: n_dname := substrb('@'||l_dname, 1, 80);
4058:
4059: if ( n_dname = l_dname ) then
4060: Wf_Core.Token('DNAME', l_display_name);
4061: Wf_Core.Token('NAME', p_item_type||':'||p_name||':'||
4062: to_char(l_version));
4063: Wf_Core.Token('CONFLICT_NAME', conflict_name);
4064: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
4065: exit;
4059: if ( n_dname = l_dname ) then
4060: Wf_Core.Token('DNAME', l_display_name);
4061: Wf_Core.Token('NAME', p_item_type||':'||p_name||':'||
4062: to_char(l_version));
4063: Wf_Core.Token('CONFLICT_NAME', conflict_name);
4064: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
4065: exit;
4066: end if;
4067: exception
4060: Wf_Core.Token('DNAME', l_display_name);
4061: Wf_Core.Token('NAME', p_item_type||':'||p_name||':'||
4062: to_char(l_version));
4063: Wf_Core.Token('CONFLICT_NAME', conflict_name);
4064: Wf_Core.Raise('WFSQL_UNIQUE_NAME');
4065: exit;
4066: end if;
4067: exception
4068: when no_data_found then
4092: and VERSION = l_version;
4093:
4094: exception
4095: when OTHERS then
4096: Wf_Core.Context('Wf_Load', 'Update_Activity', p_item_type, p_name,
4097: p_display_name);
4098: raise;
4099: end;
4100:
4151: return id;
4152:
4153: exception
4154: when OTHERS then
4155: Wf_Core.Context('Wf_Load', 'Get_Activity_Instance', p_process_item_type,
4156: p_process_name, p_process_version);
4157: return (-1);
4158: end;
4159:
4178:
4179: return l_actname;
4180: exception
4181: when OTHERS then
4182: Wf_Core.Context('Wf_Load', 'GetActNameFromInstId',
4183: to_char(p_instance_id));
4184: return null;
4185: end;
4186: */
4278: end if;
4279: end if;
4280: exception
4281: when OTHERS then
4282: Wf_Core.Context('Wf_Load', 'Get_Activity_Transition',
4283: to_char(p_from_activity),
4284: to_char(p_to_activity),
4285: p_result_code
4286: );
4314: i := i + 1;
4315: end loop;
4316: exception
4317: when OTHERS then
4318: Wf_Core.Context('Wf_Load', 'Get_Attribute_Names', p_item_type, p_suffix);
4319: raise;
4320: end;
4321:
4322:
4350: i := i + 1;
4351: end loop;
4352: exception
4353: when OTHERS then
4354: Wf_Core.Context('Wf_Load', 'Get_Notif_Activity_Names',
4355: p_item_type, p_suffix);
4356: raise;
4357: end;
4358:
4383: i := i + 1;
4384: end loop;
4385: exception
4386: when OTHERS then
4387: Wf_Core.Context('Wf_Load', 'Get_Message_Names', p_item_type, p_suffix);
4388: raise;
4389: end;
4390:
4391: -- Get_Process_Activity_Instances
4419: i := i + 1;
4420: end loop;
4421: exception
4422: when OTHERS then
4423: Wf_Core.Context('Wf_Load', 'Get_Process_Activity_Instances',
4424: p_process_item_type, p_process_name, p_process_version);
4425: raise;
4426: end;
4427:
4453: where LOOKUP_TYPE = x_lookup_type
4454: and LOOKUP_CODE = x_lookup_code;
4455: exception
4456: when OTHERS then
4457: Wf_Core.Context('Wf_Load', 'Get_Lookup', x_lookup_type, x_lookup_code);
4458: raise;
4459: end;
4460:
4461: --
4519: x_level_error=>x_level_error
4520: );
4521: exception
4522: when OTHERS then
4523: Wf_Core.Context('Wf_Load', 'Update_Lookup', x_lookup_type, x_lookup_code);
4524: raise;
4525: end;
4526:
4527:
4550: i := i + 1;
4551: end loop;
4552: exception
4553: when OTHERS then
4554: Wf_Core.Context('Wf_Load', 'Get_Lookup_Codes', p_lookup_type);
4555: raise;
4556: end;
4557:
4558: --
4596: begin
4597: -- first check the iteration to avoid infinite loop
4598: if (iteration > 7) then
4599: -- debug only
4600: -- Wf_Core.Context('Wf_Load', 'Activity_Exist_In_Process_Overflown',
4601: -- p_process_item_type, p_process_name,
4602: -- nvl(p_activity_item_type, p_process_item_type),
4603: -- p_activity_name);
4604: return FALSE;
4651: end if;
4652:
4653: exception
4654: when OTHERS then
4655: Wf_Core.Context('Wf_Load', 'Activity_Exist_In_Process',
4656: p_process_item_type, p_process_name,
4657: nvl(p_activity_item_type, p_process_item_type),
4658: p_activity_name);
4659: raise;