DBA Data[Home] [Help]

APPS.WF_LOAD SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 14

  x_wf_selector in varchar2,
  x_read_role in varchar2,
  x_write_role in varchar2,
  x_execute_role in varchar2,
  x_persistence_type in varchar2,
  x_persistence_days in varchar2,
  x_level_error out NOCOPY number
) is
  row_id varchar2(30);
Line: 36

    select NAME, DISPLAY_NAME, NAME
    into conflict_name, l_dname, l_name
    from WF_ITEM_TYPES_VL
    where DISPLAY_NAME = x_display_name
    and NAME <> x_name;
Line: 47

        select NAME, DISPLAY_NAME
        into conflict_name, l_dname
        from WF_ITEM_TYPES_VL
        where DISPLAY_NAME = n_dname
        and NAME <> l_name;
Line: 91

    select PROTECT_LEVEL, CUSTOM_LEVEL
    into protection_level, customization_level
    from WF_ITEM_TYPES_VL
    where NAME = x_name;
Line: 109

    Wf_Item_Types_Pkg.Update_Row(
      x_name => x_name,
      x_protect_level => x_protect_level,
      x_custom_level => x_custom_level,
      x_wf_selector => x_wf_selector,
      x_read_role => x_read_role,
      x_write_role => x_write_role,
      x_execute_role => x_execute_role,
      x_display_name => n_dname,
      x_description => x_description,
      x_persistence_type => x_persistence_type,
      x_persistence_days => l_persistence_days
    );
Line: 138

      Wf_Item_Types_Pkg.Insert_Row(
         x_rowid => row_id,
         x_name => x_name,
         x_protect_level => x_protect_level,
         x_custom_level => x_custom_level,
         x_wf_selector => x_wf_selector,
         x_read_role => x_read_role,
         x_write_role => x_write_role,
         x_execute_role => x_execute_role,
         x_display_name => n_dname,
         x_description => x_description,
         x_persistence_type => x_persistence_type,
         x_persistence_days => l_persistence_days
      );
Line: 178

  update WF_ITEM_ATTRIBUTES set
    SEQUENCE = -1
  where ITEM_TYPE = itemtype
  and SEQUENCE = oldseq;
Line: 186

      update WF_ITEM_ATTRIBUTES set
        SEQUENCE = SEQUENCE - 1
      where ITEM_TYPE = itemtype
      and SEQUENCE = i;
Line: 194

      update WF_ITEM_ATTRIBUTES set
        SEQUENCE = SEQUENCE + 1
      where ITEM_TYPE = itemtype
      and SEQUENCE = i;
Line: 202

  update WF_ITEM_ATTRIBUTES set
    SEQUENCE = newseq
  where ITEM_TYPE = itemtype
  and SEQUENCE = -1;
Line: 252

    select ITEM_TYPE||':'||NAME, DISPLAY_NAME, NAME
    into conflict_name, l_dname, l_name
    from WF_ITEM_ATTRIBUTES_VL
    where DISPLAY_NAME = x_display_name
    and ITEM_TYPE = x_item_type
    and NAME <> x_name;
Line: 264

        select ITEM_TYPE||':'||NAME, DISPLAY_NAME
        into conflict_name, l_dname
        from WF_ITEM_ATTRIBUTES_VL
        where DISPLAY_NAME = n_dname
        and ITEM_TYPE = x_item_type
        and NAME <> l_name;
Line: 320

    select PROTECT_LEVEL, CUSTOM_LEVEL, SEQUENCE
    into protection_level, customization_level, old_sequence
    from WF_ITEM_ATTRIBUTES_VL
    where ITEM_TYPE = x_item_type
    and NAME = x_name;
Line: 347

    Wf_Item_Attributes_Pkg.Update_Row(
      x_item_type => x_item_type,
      x_name => x_name,
      x_sequence => x_sequence,
      x_type => x_type,
      x_protect_level => x_protect_level,
      x_custom_level => x_custom_level,
      x_subtype => x_subtype,
      x_format => x_format,
      x_text_default => l_text_default,
      x_number_default => l_number_default,
      x_date_default => l_date_default,
      x_display_name => n_dname,
      x_description => x_description
    );
Line: 380

      select nvl(max(SEQUENCE), -1)+1
      into old_sequence
      from WF_ITEM_ATTRIBUTES
      where ITEM_TYPE = x_item_type;
Line: 393

      Wf_Item_Attributes_Pkg.Insert_Row(
        x_rowid => row_id,
        x_item_type => x_item_type,
        x_name => x_name,
        x_sequence => x_sequence,
        x_type => x_type,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_subtype => x_subtype,
        x_format => x_format,
        x_text_default => l_text_default,
        x_number_default => l_number_default,
        x_date_default => l_date_default,
        x_display_name => n_dname,
        x_description => x_description
      );
Line: 447

    select LOOKUP_TYPE, DISPLAY_NAME, LOOKUP_TYPE
    into conflict_name, l_dname, l_name
    from WF_LOOKUP_TYPES
    where DISPLAY_NAME = x_display_name
    and LOOKUP_TYPE <> x_lookup_type;
Line: 458

        select LOOKUP_TYPE, DISPLAY_NAME
        into conflict_name, l_dname
        from WF_LOOKUP_TYPES
        where DISPLAY_NAME = n_dname
        and LOOKUP_TYPE <> l_name;
Line: 499

    select PROTECT_LEVEL, CUSTOM_LEVEL
    into protection_level, customization_level
    from WF_LOOKUP_TYPES
    where LOOKUP_TYPE = x_lookup_type;
Line: 517

    Wf_Lookup_Types_Pkg.Update_Row(
      x_lookup_type => x_lookup_type,
      x_item_type => x_item_type,
      x_protect_level => x_protect_level,
      x_custom_level => x_custom_level,
      x_display_name => n_dname,
      x_description => x_description
    );
Line: 541

      Wf_Lookup_Types_Pkg.Insert_Row(
        x_rowid => row_id,
        x_lookup_type => x_lookup_type,
        x_item_type => x_item_type,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_display_name => n_dname,
        x_description => x_description
      );
Line: 587

    select LOOKUP_TYPE||':'||LOOKUP_CODE, MEANING, LOOKUP_CODE
    into conflict_name, l_dname, l_name
    from WF_LOOKUPS
    where MEANING = x_meaning
    and LOOKUP_TYPE = x_lookup_type
    and LOOKUP_CODE <> x_lookup_code;
Line: 599

        select LOOKUP_TYPE||':'||LOOKUP_CODE, MEANING
        into conflict_name, l_dname
        from WF_LOOKUPS
        where MEANING = n_dname
        and LOOKUP_TYPE = x_lookup_type
        and LOOKUP_CODE <> l_name;
Line: 646

    select PROTECT_LEVEL, CUSTOM_LEVEL
    into protection_level, customization_level
    from WF_LOOKUPS
    where LOOKUP_TYPE = x_lookup_type
    and LOOKUP_CODE = x_lookup_code;
Line: 665

    Wf_Lookups_Pkg.Update_Row(
      x_lookup_type => x_lookup_type,
      x_lookup_code => x_lookup_code,
      x_protect_level => x_protect_level,
      x_custom_level => x_custom_level,
      x_meaning => n_dname,
      x_description => x_description
    );
Line: 690

      Wf_Lookups_Pkg.Insert_Row(
        x_rowid => row_id,
        x_lookup_type => x_lookup_type,
        x_lookup_code => x_lookup_code,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_meaning => n_dname,
        x_description => x_description
      );
Line: 735

    select PROTECT_LEVEL, CUSTOM_LEVEL
    into protection_level, customization_level
    from WF_MESSAGES_VL
    where TYPE = x_type
    and NAME = x_name;
Line: 754

    Wf_Messages_Pkg.Update_Row(
      x_type => x_type,
      x_name => x_name,
      x_protect_level => x_protect_level,
      x_custom_level => x_custom_level,
      x_default_priority => x_default_priority,
      x_read_role => x_read_role,
      x_write_role => x_write_role,
      x_display_name => x_display_name,
      x_description => x_description,
      x_subject => x_subject,
      x_body => x_body,
      x_html_body => x_html_body
    );
Line: 784

      Wf_Messages_Pkg.Insert_Row(
        x_rowid => row_id,
        x_type => x_type,
        x_name => x_name,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_default_priority => x_default_priority,
        x_read_role => x_read_role,
        x_write_role => x_write_role,
        x_display_name => x_display_name,
        x_description => x_description,
        x_subject => x_subject,
        x_body => x_body,
        x_html_body => x_html_body
      );
Line: 826

  update WF_MESSAGE_ATTRIBUTES set
    SEQUENCE = -1
  where MESSAGE_TYPE = msgtype
  and MESSAGE_NAME = msgname
  and SEQUENCE = oldseq;
Line: 835

      update WF_MESSAGE_ATTRIBUTES set
        SEQUENCE = SEQUENCE - 1
      where MESSAGE_TYPE = msgtype
      and MESSAGE_NAME = msgname
      and SEQUENCE = i;
Line: 844

      update WF_MESSAGE_ATTRIBUTES set
        SEQUENCE = SEQUENCE + 1
      where MESSAGE_TYPE = msgtype
      and MESSAGE_NAME = msgname
      and SEQUENCE = i;
Line: 853

  update WF_MESSAGE_ATTRIBUTES set
    SEQUENCE = newseq
  where MESSAGE_TYPE = msgtype
  and MESSAGE_NAME = msgname
  and SEQUENCE = -1;
Line: 907

    select MESSAGE_TYPE||':'||MESSAGE_NAME||':'||NAME, DISPLAY_NAME, NAME
    into conflict_name, l_dname, l_name
    from WF_MESSAGE_ATTRIBUTES_VL
    where DISPLAY_NAME = n_dname
    and MESSAGE_TYPE = x_message_type
    and MESSAGE_NAME = x_message_name
    and NAME <> x_name;
Line: 920

        select MESSAGE_TYPE||':'||MESSAGE_NAME||':'||NAME, DISPLAY_NAME
        into conflict_name, l_dname
        from WF_MESSAGE_ATTRIBUTES_VL
        where DISPLAY_NAME = n_dname
        and MESSAGE_TYPE = x_message_type
        and MESSAGE_NAME = x_message_name
        and NAME <> l_name;
Line: 979

    select PROTECT_LEVEL, CUSTOM_LEVEL, SEQUENCE
    into protection_level, customization_level, old_sequence
    from WF_MESSAGE_ATTRIBUTES_VL
    where MESSAGE_TYPE = x_message_type
    and MESSAGE_NAME = x_message_name
    and NAME = x_name;
Line: 1007

    Wf_Message_Attributes_Pkg.Update_Row(
      x_message_type => x_message_type,
      x_message_name => x_message_name,
      x_name => x_name,
      x_sequence => x_sequence,
      x_type => x_type,
      x_subtype => x_subtype,
      x_protect_level => x_protect_level,
      x_custom_level => x_custom_level,
      x_format => x_format,
      x_text_default => l_text_default,
      x_number_default => l_number_default,
      x_date_default => l_date_default,
      x_value_type => x_value_type,
      x_display_name => n_dname,
      x_description => x_description,
      x_attach => x_attach
    );
Line: 1029

      select nvl(max(SEQUENCE), -1)+1
      into old_sequence
      from WF_MESSAGE_ATTRIBUTES
      where MESSAGE_TYPE = x_message_type
      and MESSAGE_NAME = x_message_name;
Line: 1043

      Wf_Message_Attributes_Pkg.Insert_Row(
        x_rowid => row_id,
        x_message_type => x_message_type,
        x_message_name => x_message_name,
        x_name => x_name,
        x_sequence => x_sequence,
        x_type => x_type,
        x_subtype => x_subtype,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_format => x_format,
        x_text_default => l_text_default,
        x_number_default => l_number_default,
        x_date_default => l_date_default,
        x_value_type => x_value_type,
        x_display_name => n_dname,
        x_description => x_description,
        x_attach => x_attach
      );
Line: 1111

  noinsert pls_integer := -1;     /* always insert by default */
Line: 1128

    select PROTECT_LEVEL, CUSTOM_LEVEL, VERSION, BEGIN_DATE, END_DATE
    into protection_level, customization_level,
         old_version, old_begin_date, old_end_date
    from WF_ACTIVITIES_VL
    where ITEM_TYPE = x_item_type
    and NAME = x_name
    and x_effective_date >= BEGIN_DATE
    and x_effective_date < nvl(END_DATE, x_effective_date+1);
Line: 1158

      select min(BEGIN_DATE)
      into old_end_date
      from WF_ACTIVITIES_VL
      where ITEM_TYPE = x_item_type
      and NAME = x_name
      and BEGIN_DATE >= x_effective_date;
Line: 1191

    select nvl(max(VERSION), 1), count(1)
    into new_version, noinsert
    from WF_ACTIVITIES
    where ITEM_TYPE = x_item_type
    and NAME = x_name;
Line: 1199

    select nvl(max(VERSION), 0) + 1
    into new_version
    from WF_ACTIVITIES
    where ITEM_TYPE = x_item_type
    and NAME = x_name;
Line: 1207

    update WF_ACTIVITIES set
      END_DATE = x_effective_date
    where ITEM_TYPE = x_item_type
    and NAME = x_name
    and VERSION = old_version;
Line: 1221

    select ITEM_TYPE||':'||NAME||':'||to_char(VERSION), DISPLAY_NAME, NAME
    into conflict_name, l_dname, l_name
    from WF_ACTIVITIES_VL
    where DISPLAY_NAME = n_dname
    and ITEM_TYPE = x_item_type
    and x_effective_date >= BEGIN_DATE
    and x_effective_date < nvl(END_DATE, x_effective_date+1)
    and NAME <> x_name;
Line: 1235

        select ITEM_TYPE||':'||NAME||':'||to_char(VERSION), DISPLAY_NAME
        into conflict_name, l_dname
        from WF_ACTIVITIES_VL
        where DISPLAY_NAME = n_dname
        and ITEM_TYPE = x_item_type
        and x_effective_date >= BEGIN_DATE
        and x_effective_date < nvl(END_DATE, x_effective_date+1)
        and NAME <> l_name;
Line: 1285

  if (noinsert <= 0) then
    if (x_event_filter is null and x_event_type = null) then

      Wf_Activities_Pkg.Insert_Row(
        x_rowid => row_id,
        x_item_type => x_item_type,
        x_name => x_name,
        x_version => new_version,
        x_type => x_type,
        x_rerun => x_rerun,
        x_expand_role => x_expand_role,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_begin_date => x_effective_date,
        x_end_date => old_end_date,
        x_function => x_function,
        x_function_type => x_function_type,
        x_result_type => x_result_type,
        x_cost => x_cost,
        x_read_role => x_read_role,
        x_write_role => x_write_role,
        x_execute_role => x_execute_role,
        x_icon_name => x_icon_name,
        x_message => x_message,
        x_error_process => x_error_process,
        x_display_name => n_dname,
        x_description => x_description,
        x_error_item_type => x_error_item_type,
        x_runnable_flag => x_runnable_flag
      );
Line: 1318

      Wf_Activities_Pkg.Insert_Row(
        x_rowid => row_id,
        x_item_type => x_item_type,
        x_name => x_name,
        x_version => new_version,
        x_type => x_type,
        x_rerun => x_rerun,
        x_expand_role => x_expand_role,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_begin_date => x_effective_date,
        x_end_date => old_end_date,
        x_function => x_function,
        x_function_type => x_function_type,
        x_result_type => x_result_type,
        x_cost => x_cost,
        x_read_role => x_read_role,
        x_write_role => x_write_role,
        x_execute_role => x_execute_role,
        x_icon_name => x_icon_name,
        x_message => x_message,
        x_error_process => x_error_process,
        x_display_name => n_dname,
        x_description => x_description,
        x_error_item_type => x_error_item_type,
        x_runnable_flag => x_runnable_flag,
        x_event_filter => x_event_filter,
        x_event_type => x_event_type
      );
Line: 1392

      update WF_ACTIVITIES
        set  BEGIN_DATE = x_effective_date,
             END_DATE = to_date(NULL)
      where ITEM_TYPE = x_item_type
      and NAME = x_name
      and VERSION = new_version;
Line: 1408

      update WF_ACTIVITIES
        set  END_DATE = to_date(NULL)
      where ITEM_TYPE = x_item_type
      and NAME = x_name
      and VERSION = new_version;
Line: 1517

  update WF_ACTIVITY_ATTRIBUTES set
    SEQUENCE = -1
  where ACTIVITY_ITEM_TYPE = acttype
  and ACTIVITY_NAME = actname
  and ACTIVITY_VERSION = actver
  and SEQUENCE = oldseq;
Line: 1527

      update WF_ACTIVITY_ATTRIBUTES set
        SEQUENCE = SEQUENCE - 1
      where ACTIVITY_ITEM_TYPE = acttype
      and ACTIVITY_NAME = actname
      and ACTIVITY_VERSION = actver
      and SEQUENCE = i;
Line: 1537

      update WF_ACTIVITY_ATTRIBUTES set
        SEQUENCE = SEQUENCE + 1
      where ACTIVITY_ITEM_TYPE = acttype
      and ACTIVITY_NAME = actname
      and ACTIVITY_VERSION = actver
      and SEQUENCE = i;
Line: 1547

  update WF_ACTIVITY_ATTRIBUTES set
    SEQUENCE = newseq
  where ACTIVITY_ITEM_TYPE = acttype
  and ACTIVITY_NAME = actname
  and ACTIVITY_VERSION = actver
  and SEQUENCE = -1;
Line: 1604

    select PROTECT_LEVEL, CUSTOM_LEVEL, SEQUENCE
    into protection_level, customization_level, old_sequence
    from WF_ACTIVITY_ATTRIBUTES_VL
    where ACTIVITY_ITEM_TYPE = x_activity_item_type
    and ACTIVITY_NAME = x_activity_name
    and ACTIVITY_VERSION = x_activity_version
    and NAME = x_name;
Line: 1635

    Wf_Activity_Attributes_Pkg.Update_Row(
      x_activity_item_type => x_activity_item_type,
      x_activity_name => x_activity_name,
      x_activity_version => x_activity_version,
      x_name => x_name,
      x_sequence => x_sequence,
      x_type => x_type,
      x_value_type => x_value_type,
      x_protect_level => x_protect_level,
      x_custom_level => x_custom_level,
      x_subtype => x_subtype,
      x_format => x_format,
      x_text_default => l_text_default,
      x_number_default => l_number_default,
      x_date_default => l_date_default,
      x_display_name => x_display_name,
      x_description => x_description
    );
Line: 1671

      select nvl(max(SEQUENCE), -1)+1
      into old_sequence
      from WF_ACTIVITY_ATTRIBUTES
      where ACTIVITY_ITEM_TYPE = x_activity_item_type
      and ACTIVITY_NAME = x_activity_name
      and ACTIVITY_VERSION = x_activity_version;
Line: 1688

      Wf_Activity_Attributes_Pkg.Insert_Row(
        x_rowid => row_id,
        x_activity_item_type => x_activity_item_type,
        x_activity_name => x_activity_name,
        x_activity_version => x_activity_version,
        x_name => x_name,
        x_sequence => x_sequence,
        x_type => x_type,
        x_value_type => x_value_type,
        x_protect_level => x_protect_level,
        x_custom_level => x_custom_level,
        x_subtype => x_subtype,
        x_format => x_format,
        x_text_default => l_text_default,
        x_number_default => l_number_default,
        x_date_default => l_date_default,
        x_display_name => x_display_name,
        x_description => x_description
      );
Line: 1742

  noinsert  pls_integer := 1;
Line: 1760

        select WF_PROCESS_ACTIVITIES_S.NEXTVAL
        into   x_instance_id
        from   sys.dual;
Line: 1764

        raise NO_DATA_FOUND;  --jump to insert
Line: 1766

        select PROTECT_LEVEL, CUSTOM_LEVEL
        into protection_level, customization_level
        from WF_PROCESS_ACTIVITIES
        where INSTANCE_ID = x_instance_id;
Line: 1791

        select NAME into l_perform_role
          from WF_ROLES
         where DISPLAY_NAME = x_perform_role
           and rownum < 2;
Line: 1812

    update WF_PROCESS_ACTIVITIES set
      PROCESS_ITEM_TYPE = x_process_item_type,
      PROCESS_NAME = x_process_name,
      PROCESS_VERSION = x_process_version,
      ACTIVITY_ITEM_TYPE = x_activity_item_type,
      ACTIVITY_NAME = x_activity_name,
      INSTANCE_LABEL = x_instance_label,
      PROTECT_LEVEL = x_protect_level,
      CUSTOM_LEVEL = x_custom_level,
      START_END = x_start_end,
      DEFAULT_RESULT = x_default_result,
      ICON_GEOMETRY = x_icon_geometry,
      PERFORM_ROLE = l_perform_role,
      PERFORM_ROLE_TYPE = l_perform_role_type,
      USER_COMMENT = x_user_comment
    where INSTANCE_ID = x_instance_id;
Line: 1848

          select NAME into l_perform_role
            from WF_ROLES
           where DISPLAY_NAME = x_perform_role
             and rownum < 2;
Line: 1869

      select nvl(max(VERSION), 1), count(1)
      into new_version, noinsert
      from WF_ACTIVITIES
      where ITEM_TYPE = x_process_item_type
      and NAME = 'ROOT';
Line: 1875

      if (noinsert <= 0) then
        WF_LOAD.UPLOAD_ACTIVITY(
          x_item_type=>x_process_item_type,
          x_name=>'ROOT',
          x_type=>'FOLDER',
          x_display_name=>'ROOT',
          x_description=>'',
          x_rerun=>'RESET',
          x_protect_level=>x_protect_level,
          x_custom_level=>x_custom_level,
          x_effective_date=>sysdate,
          x_function=>'',
          x_function_type =>'',
          x_result_type=>'*',
          x_cost=>0,
          x_read_role=>'',
          x_write_role=>'',
          x_execute_role=>'',
          x_icon_name=>'ROOT',
          x_message=>'',
          x_error_process=>'',
          x_expand_role=>'N',
          x_error_item_type =>'WFERROR',
          x_runnable_flag =>'N',
          x_event_filter => '',
          x_event_type => '',
          x_log_message=>dummy_log_message,
          x_version=>dummy_version,
          x_level_error=>dummy_level_error);
Line: 1909

      select count(1)
        into noinsert
        from WF_PROCESS_ACTIVITIES
       where PROCESS_NAME = 'ROOT'
         and ACTIVITY_ITEM_TYPE = x_process_item_type
         and ACTIVITY_NAME = x_activity_name
         and  rownum=1;
Line: 1918

      if (x_process_name <> 'ROOT' or noinsert <= 0) then
        -- Insert new row
        insert into WF_PROCESS_ACTIVITIES (
          PROCESS_ITEM_TYPE,
          PROCESS_NAME,
          PROCESS_VERSION,
          ACTIVITY_ITEM_TYPE,
          ACTIVITY_NAME,
          INSTANCE_ID,
          INSTANCE_LABEL,
          PROTECT_LEVEL,
          CUSTOM_LEVEL,
          START_END,
          DEFAULT_RESULT,
          ICON_GEOMETRY,
          PERFORM_ROLE,
          PERFORM_ROLE_TYPE,
          USER_COMMENT
         ) values (
          x_process_item_type,
          x_process_name,
          x_process_version,
          x_activity_item_type,
          x_activity_name,
          x_instance_id,
          x_instance_label,
          x_protect_level,
          x_custom_level,
          x_start_end,
          x_default_result,
          x_icon_geometry,
          l_perform_role,
          l_perform_role_type,
          x_user_comment
        );
Line: 1960

      if (x_process_name <> 'ROOT' and noinsert <= 0) then
        -- Insert a root process activity
        WF_LOAD.UPLOAD_PROCESS_ACTIVITY(
          x_process_item_type=>x_process_item_type,
          x_process_name=>'ROOT',
          x_process_version=>new_version,
          x_activity_item_type=>x_process_item_type,
          x_activity_name=>x_process_name,
          x_instance_id=>root_instance_id,
          x_instance_label=>x_process_name,
          x_protect_level=>x_protect_level,
          x_custom_level=>x_custom_level,
          x_start_end=>'',
          x_default_result=>'',
          x_icon_geometry=>'',
          x_perform_role=>'',
          x_perform_role_type=>'CONSTANT',
          x_user_comment=>'',
          x_level_error=>dummy_level_error
        );
Line: 2032

      select WAA.TYPE
      into l_type
      from WF_PROCESS_ACTIVITIES WPA, WF_ACTIVITIES WA,
           WF_ACTIVITY_ATTRIBUTES WAA
      where WPA.INSTANCE_ID = x_process_activity_id
      and WPA.ACTIVITY_ITEM_TYPE = WA.ITEM_TYPE
      and WPA.ACTIVITY_NAME = WA.NAME
      and x_effective_date >= WA.BEGIN_DATE
      and x_effective_date < nvl(WA.END_DATE, x_effective_date+1)
      and WA.ITEM_TYPE = WAA.ACTIVITY_ITEM_TYPE
      and WA.NAME = WAA.ACTIVITY_NAME
      and WA.VERSION = WAA.ACTIVITY_VERSION
      and WAA.NAME = x_name;
Line: 2070

    select PROTECT_LEVEL, CUSTOM_LEVEL
    into protection_level, customization_level
    from WF_ACTIVITY_ATTR_VALUES
    where PROCESS_ACTIVITY_ID = x_process_activity_id
    and NAME = x_name;
Line: 2089

    update WF_ACTIVITY_ATTR_VALUES set
      PROTECT_LEVEL = x_protect_level,
      CUSTOM_LEVEL = x_custom_level,
      TEXT_VALUE = l_text_value,
      NUMBER_VALUE = l_number_value,
      DATE_VALUE = l_date_value,
      VALUE_TYPE = x_value_type
    where PROCESS_ACTIVITY_ID = x_process_activity_id
    and NAME = x_name;
Line: 2115

      insert into WF_ACTIVITY_ATTR_VALUES (
        PROCESS_ACTIVITY_ID,
        NAME,
        PROTECT_LEVEL,
        CUSTOM_LEVEL,
        TEXT_VALUE,
        NUMBER_VALUE,
        DATE_VALUE,
        VALUE_TYPE
      ) values (
        x_process_activity_id,
        x_name,
        x_protect_level,
        x_custom_level,
        l_text_value,
        l_number_value,
        l_date_value,
        x_value_type
      );
Line: 2164

    select PROTECT_LEVEL, CUSTOM_LEVEL
    into protection_level, customization_level
    from WF_ACTIVITY_TRANSITIONS
    where FROM_PROCESS_ACTIVITY = x_from_process_activity
    and RESULT_CODE = x_result_code
    and TO_PROCESS_ACTIVITY = x_to_process_activity;
Line: 2184

    update WF_ACTIVITY_TRANSITIONS set
      FROM_PROCESS_ACTIVITY = x_from_process_activity,
      RESULT_CODE = x_result_code,
      TO_PROCESS_ACTIVITY = x_to_process_activity,
      PROTECT_LEVEL = x_protect_level,
      CUSTOM_LEVEL = x_custom_level,
      ARROW_GEOMETRY = x_arrow_geometry
    where FROM_PROCESS_ACTIVITY = x_from_process_activity
    and RESULT_CODE = x_result_code
    and TO_PROCESS_ACTIVITY = x_to_process_activity;
Line: 2211

      insert into WF_ACTIVITY_TRANSITIONS (
        FROM_PROCESS_ACTIVITY,
        RESULT_CODE,
        TO_PROCESS_ACTIVITY,
        PROTECT_LEVEL,
        CUSTOM_LEVEL,
        ARROW_GEOMETRY
      ) values (
        x_from_process_activity,
        x_result_code,
        x_to_process_activity,
        x_protect_level,
        x_custom_level,
        x_arrow_geometry
      );
Line: 2268

procedure DELETE_LOOKUP_TYPE(
  x_lookup_type in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2280

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_LOOKUP_TYPES
  where LOOKUP_TYPE = x_lookup_type;
Line: 2298

  Delete_Lookups(x_lookup_type, x_level_error);
Line: 2300

  Wf_Lookup_Types_Pkg.Delete_Row(x_lookup_type => x_lookup_type);
Line: 2306

    Wf_Core.Context('Wf_Load', 'Delete_Lookup_Type', x_lookup_type);
Line: 2308

end DELETE_LOOKUP_TYPE;
Line: 2313

procedure DELETE_LOOKUP(
  x_lookup_type in varchar2,
  x_lookup_code in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2326

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_LOOKUPS
  where LOOKUP_TYPE = x_lookup_type
  and LOOKUP_CODE = x_lookup_code;
Line: 2344

  Wf_Lookups_Pkg.Delete_Row(
      x_lookup_type => x_lookup_type,
      x_lookup_code => x_lookup_code
  );
Line: 2353

    Wf_Core.Context('Wf_Load', 'Delete_Lookup', x_lookup_type, x_lookup_code);
Line: 2355

end DELETE_LOOKUP;
Line: 2360

procedure DELETE_LOOKUPS(
  x_lookup_type in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2371

  select MIN(protect_level), MAX(custom_level)
  into protection_level, customization_level
  from WF_LOOKUP_TYPES_TL
  where LOOKUP_TYPE = X_LOOKUP_TYPE;
Line: 2388

  delete from WF_LOOKUPS_TL
  where LOOKUP_TYPE = X_LOOKUP_TYPE;
Line: 2395

    wf_core.context('WF_LOAD', 'DELETE_LOOKUPS');
Line: 2397

end DELETE_LOOKUPS;
Line: 2402

procedure DELETE_ITEM_TYPE(
  x_name in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2420

  select PROTECT_LEVEL, CUSTOM_LEVEL, PERSISTENCE_TYPE
  into protection_level, customization_level, l_persistence_type
  from WF_ITEM_TYPES_VL
  where NAME = x_name;
Line: 2447

  Delete_Item_Attributes(x_name, x_level_error);
Line: 2452

    select 1
    into dummy
    from sys.dual
    where not exists
      (select 1
      from WF_LOOKUP_TYPES
      where ITEM_TYPE = x_name)
    and not exists
      (select 1
      from WF_ACTIVITIES
      where ITEM_TYPE = x_name)
    and not exists
      (select 1
      from WF_MESSAGES
      where TYPE = x_name);
Line: 2473

  Wf_Item_Types_Pkg.Delete_Row(x_name=>x_name);
Line: 2479

    Wf_Core.Context('Wf_Load', 'Delete_Item_Type', x_name);
Line: 2481

end DELETE_ITEM_TYPE;
Line: 2486

procedure DELETE_ITEM_ATTRIBUTE(
  x_item_type in varchar2,
  x_name in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2499

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_ITEM_ATTRIBUTES_VL
  where ITEM_TYPE = x_item_type
  and NAME = x_name;
Line: 2517

  Wf_Item_Attributes_Pkg.Delete_Row(
    x_item_type => x_item_type,
    x_name => x_name);
Line: 2525

    Wf_Core.Context('Wf_Load', 'Delete_Item_Attribute', x_item_type, x_name);
Line: 2527

end DELETE_ITEM_ATTRIBUTE;
Line: 2532

procedure DELETE_ITEM_ATTRIBUTES(
  x_item_type in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2544

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_ITEM_TYPES_VL
  where NAME = x_item_type;
Line: 2561

  delete from WF_ITEM_ATTRIBUTES_TL
  where ITEM_TYPE = X_ITEM_TYPE;
Line: 2564

  delete from WF_ITEM_ATTRIBUTES
  where ITEM_TYPE = X_ITEM_TYPE;
Line: 2570

    Wf_Core.Context('Wf_Load', 'Delete_Item_Attributes', x_item_type);
Line: 2572

end DELETE_ITEM_ATTRIBUTES;
Line: 2577

procedure DELETE_MESSAGE(
  x_type in varchar2,
  x_name in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2595

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_MESSAGES
  where TYPE = x_type
  and NAME = x_name;
Line: 2614

  Delete_Message_Attributes(x_type, x_name, x_level_error);
Line: 2619

    select 1
    into dummy
    from sys.dual
    where not exists
      (select 1
      from WF_ACTIVITIES
      where ITEM_TYPE = x_type
      and MESSAGE = x_name)
    and not exists
      (select 1
      from WF_NOTIFICATIONS
      where MESSAGE_TYPE = x_type
      and MESSAGE_NAME = x_name);
Line: 2638

  Wf_Messages_Pkg.Delete_Row(x_type => x_type, x_name => x_name);
Line: 2644

    Wf_Core.Context('Wf_Load', 'Delete_Message', x_type, x_name);
Line: 2646

end DELETE_MESSAGE;
Line: 2651

procedure DELETE_MESSAGE_ATTRIBUTE(
  x_message_type in varchar2,
  x_message_name in varchar2,
  x_name in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2663

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_MESSAGE_ATTRIBUTES_VL
  where MESSAGE_TYPE = x_message_type
  and MESSAGE_NAME = x_message_name
  and NAME = x_name;
Line: 2682

  Wf_Message_Attributes_Pkg.Delete_Row(
      x_message_type => x_message_type,
      x_message_name => x_message_name,
      x_name => x_name);
Line: 2691

    Wf_Core.Context('Wf_Load', 'Delete_Message_Attribute', x_message_type,
        x_message_name, x_name);
Line: 2694

end DELETE_MESSAGE_ATTRIBUTE;
Line: 2699

procedure DELETE_MESSAGE_ATTRIBUTES(
  x_message_type in varchar2,
  x_message_name in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level NUMBER;
Line: 2712

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_MESSAGES
  where TYPE = x_message_type
  and NAME = x_message_name;
Line: 2730

  delete from WF_MESSAGE_ATTRIBUTES_TL
  where MESSAGE_TYPE = x_message_type
  and MESSAGE_NAME = x_message_name;
Line: 2734

  delete from WF_MESSAGE_ATTRIBUTES
  where MESSAGE_TYPE = x_message_type
  and MESSAGE_NAME = x_message_name;
Line: 2742

    Wf_Core.Context('Wf_Load', 'Delete_Message_Attributes', x_message_type,
                    x_message_name);
Line: 2745

end DELETE_MESSAGE_ATTRIBUTES;
Line: 2750

procedure DELETE_ACTIVITY(
  x_item_type in varchar2,
  x_name in varchar2,
  x_level_error out NOCOPY number
) is
  protection_level number;
Line: 2765

  select PROTECT_LEVEL, CUSTOM_LEVEL
  into protection_level, customization_level
  from WF_ACTIVITIES_VL
  where ITEM_TYPE = x_item_type
  and NAME = x_name
  and END_DATE is null;
Line: 2785

  update WF_ACTIVITIES set
    end_date = sysdate
  where ITEM_TYPE = x_item_type
  and NAME = x_name
  and END_DATE is null;
Line: 2792

  select PERSISTENCE_TYPE
  into   l_persistence_type
  from   WF_ITEM_TYPES
  where  NAME = x_item_type;
Line: 2808

    Wf_Core.Context('Wf_Load', 'Delete_Activity', x_item_type, x_name);
Line: 2810

end DELETE_ACTIVITY;
Line: 2827

procedure Delete_Transition(
  p_previous_step in number ,
  p_next_step     in number ,
  p_result_code   in varchar2 )
is
begin
  -- Reset any caches that might be running.
  WF_CACHE.Reset;
Line: 2842

    delete WF_ACTIVITY_TRANSITIONS
      where FROM_PROCESS_ACTIVITY = p_previous_step
        and RESULT_CODE = nvl(p_result_code, RESULT_CODE);
Line: 2847

      delete WF_ACTIVITY_TRANSITIONS
        where TO_PROCESS_ACTIVITY = p_next_step
          and RESULT_CODE = nvl(p_result_code, RESULT_CODE);
Line: 2852

      delete WF_ACTIVITY_TRANSITIONS
        where FROM_PROCESS_ACTIVITY = p_previous_step
          and RESULT_CODE = nvl(p_result_code, RESULT_CODE)
          and TO_PROCESS_ACTIVITY = p_next_step;
Line: 2860

    Wf_Core.Context('Wf_Load', 'Delete_Transition', p_previous_step,
                    p_next_step, p_result_code);
Line: 2888

  select ICON_GEOMETRY, ACTIVITY_NAME, INSTANCE_LABEL
    into l_icon_geometry, p_activity_name, p_instance_label
    from WF_PROCESS_ACTIVITIES
   where instance_id = p_activity_instance;
Line: 2917

procedure UPDATE_MESSAGE (
  p_type in varchar2,
  p_name in varchar2,
  p_subject in varchar2,
  p_body in varchar2,
  p_html_body in varchar2,
  p_level_error out NOCOPY number
)
is
  l_protect_level     number;
Line: 3004

  select PROTECT_LEVEL,
         CUSTOM_LEVEL,
         DEFAULT_PRIORITY,
         DISPLAY_NAME,
         DESCRIPTION,
         SUBJECT,
         BODY,
         HTML_BODY
    into
         p_protect_level,
         p_custom_level,
         p_default_priority,
         p_display_name,
         p_description,
         p_subject,
         p_body,
         p_html_body
    from WF_MESSAGES_VL
   where TYPE = p_type
     and NAME = p_name;
Line: 3051

    wf_selector       varchar2(240),
    read_role         varchar2(320),
    write_role        varchar2(320),
    execute_role      varchar2(320),
    persistence_type  varchar2(8),
    persistence_days  varchar2(8));
Line: 3061

  select PROTECT_LEVEL, CUSTOM_LEVEL, NAME, DISPLAY_NAME, DESCRIPTION,
         TYPE, SUBTYPE, FORMAT, TEXT_DEFAULT,
         to_char(NUMBER_DEFAULT) NUMBER_DEFAULT,
         to_char(DATE_DEFAULT, 'YYYY/MM/DD HH24:MI:SS') DATE_DEFAULT,
         SEQUENCE
  from   WF_ITEM_ATTRIBUTES_VL
  where  ITEM_TYPE = itt
  order by SEQUENCE;
Line: 3071

  select PROTECT_LEVEL, CUSTOM_LEVEL, LOOKUP_TYPE, DISPLAY_NAME,
         DESCRIPTION
  from   WF_LOOKUP_TYPES
  where  ITEM_TYPE = itt
  order by LOOKUP_TYPE;
Line: 3083

  select PROTECT_LEVEL, CUSTOM_LEVEL, LOOKUP_CODE, MEANING, DESCRIPTION
  from   WF_LOOKUPS
  where  LOOKUP_TYPE = lut
  order by LOOKUP_CODE;
Line: 3089

  select PROTECT_LEVEL, CUSTOM_LEVEL, NAME, DISPLAY_NAME, DESCRIPTION,
         SUBJECT, BODY, DEFAULT_PRIORITY, READ_ROLE, WRITE_ROLE,
         HTML_BODY
  from   WF_MESSAGES_VL
  where  TYPE = itt
  order by TYPE, NAME;
Line: 3102

  select PROTECT_LEVEL, CUSTOM_LEVEL, NAME, DISPLAY_NAME, DESCRIPTION,
         TYPE, SUBTYPE, FORMAT, TEXT_DEFAULT,
         to_char(NUMBER_DEFAULT) NUMBER_DEFAULT,
         to_char(DATE_DEFAULT, 'YYYY/MM/DD HH24:MI:SS') DATE_DEFAULT,
         VALUE_TYPE, ATTACH, SEQUENCE
  from   WF_MESSAGE_ATTRIBUTES_VL
  where  MESSAGE_TYPE = itt and MESSAGE_NAME = msg
  order by SEQUENCE;
Line: 3112

  select PROTECT_LEVEL, CUSTOM_LEVEL, NAME, DISPLAY_NAME, DESCRIPTION,
         ITEM_TYPE, VERSION, TYPE, RERUN, FUNCTION, RESULT_TYPE, COST,
         ICON_NAME, MESSAGE, ERROR_PROCESS, EXPAND_ROLE,
         READ_ROLE, WRITE_ROLE, EXECUTE_ROLE,
         to_char(BEGIN_DATE, 'YYYY/MM/DD HH24:MI:SS') EFFECTIVE_DATE,
         ERROR_ITEM_TYPE, RUNNABLE_FLAG, FUNCTION_TYPE,
         EVENT_NAME, DIRECTION
  from   WF_ACTIVITIES_VL
  where  sysdate >= BEGIN_DATE
  and    (sysdate < END_DATE or END_DATE is null)
  and    ITEM_TYPE = itt
  order by item_type, name;
Line: 3134

  select PROTECT_LEVEL, CUSTOM_LEVEL, NAME, DISPLAY_NAME, DESCRIPTION,
         TYPE, SUBTYPE, FORMAT, TEXT_DEFAULT,
         to_char(NUMBER_DEFAULT) NUMBER_DEFAULT,
         to_char(DATE_DEFAULT, 'YYYY/MM/DD HH24:MI:SS') DATE_DEFAULT,
         VALUE_TYPE, SEQUENCE
  from   WF_ACTIVITY_ATTRIBUTES_VL
  where  ACTIVITY_ITEM_TYPE = itt
  and    ACTIVITY_NAME = actname
  and    ACTIVITY_VERSION = ver
  order by SEQUENCE;
Line: 3152

  select ACTIVITY_ITEM_TYPE, ACTIVITY_NAME, INSTANCE_ID, START_END,
         DEFAULT_RESULT, ICON_GEOMETRY, PERFORM_ROLE,
         USER_COMMENT, PERFORM_ROLE_TYPE, INSTANCE_LABEL,
         PROTECT_LEVEL, CUSTOM_LEVEL
  from   WF_PROCESS_ACTIVITIES
  where  PROCESS_ITEM_TYPE = itt
  and    PROCESS_NAME = actname
  and    PROCESS_VERSION = ver
  order by INSTANCE_ID;
Line: 3163

  select RESULT_CODE, TO_PROCESS_ACTIVITY, ARROW_GEOMETRY,
         PROTECT_LEVEL, CUSTOM_LEVEL
  from   WF_ACTIVITY_TRANSITIONS
  where  FROM_PROCESS_ACTIVITY = id
  order by RESULT_CODE;
Line: 3170

  select NAME, VALUE_TYPE, PROTECT_LEVEL, CUSTOM_LEVEL,
         TEXT_VALUE,
         to_char(NUMBER_VALUE) NUMBER_VALUE,
         to_char(DATE_VALUE, 'YYYY/MM/DD HH24:MI:SS') DATE_VALUE
  from   WF_ACTIVITY_ATTR_VALUES
  where  PROCESS_ACTIVITY_ID = id;
Line: 3197

    select PROTECT_LEVEL, CUSTOM_LEVEL, NAME, DISPLAY_NAME, DESCRIPTION,
           WF_SELECTOR, READ_ROLE, WRITE_ROLE, EXECUTE_ROLE,
           PERSISTENCE_TYPE,
           to_char(PERSISTENCE_DAYS) PERSISTENCE_DAYS
    into   v_itt
    from   WF_ITEM_TYPES_VL
    where  NAME = p_item_type;
Line: 3206

      Wf_Core.Context('Wf_Load', 'Selecting ITEM_TYPE', p_item_type);
Line: 3211

    select DISPLAY_NAME
    into   l_dname
    from   WF_ITEM_TYPES_VL
    where  NAME = p_destination_item_type;
Line: 3229

    x_wf_selector=> v_itt.wf_selector,
    x_read_role=> v_itt.read_role,
    x_write_role=> v_itt.write_role,
    x_execute_role=> v_itt.execute_role,
    x_persistence_type=> v_itt.persistence_type,
    x_persistence_days=> v_itt.persistence_days,
    x_level_error=> l_level_error
  );
Line: 3557

        select INSTANCE_ID into v_npac(i)
        from   WF_PROCESS_ACTIVITIES
        where  INSTANCE_LABEL = pacr.instance_label
        and    PROCESS_ITEM_TYPE = p_destination_item_type
        and    PROCESS_NAME = l_pname
        and    PROCESS_VERSION = 1;
Line: 3699

procedure Delete_Process_Activity(
  p_step in number)
is
  dummy number;
Line: 3723

  Wf_Load.Delete_Transition(p_previous_step=>p_step);
Line: 3724

  Wf_Load.Delete_Transition(p_next_step=>p_step);
Line: 3727

  delete from WF_ACTIVITY_ATTR_VALUES where PROCESS_ACTIVITY_ID = p_step;
Line: 3730

  delete from WF_PROCESS_ACTIVITIES where INSTANCE_ID = p_step;
Line: 3734

    Wf_Core.Context('Wf_Load', 'Delete_Process_Activity',
                    to_char(p_step));
Line: 3755

  select VALUE_TYPE,
         nvl(nvl(TEXT_VALUE, to_char(NUMBER_VALUE)),
             to_char(DATE_VALUE, 'YYYY/MM/DD HH24:MI:SS'))
  into   p_attribute_value_type,
         p_attribute_value
  from   WF_ACTIVITY_ATTR_VALUES
  where  PROCESS_ACTIVITY_ID = p_process_instance_id
  and    NAME = p_attribute_name;
Line: 3789

  select TYPE,
         TEXT_DEFAULT,
         to_char(NUMBER_DEFAULT),
         to_char(DATE_DEFAULT, 'YYYY/MM/DD HH24:MI:SS')
  into   p_attribute_type,
         p_attribute_value,
         l_number,
         l_date
  from   WF_ITEM_ATTRIBUTES
  where  ITEM_TYPE = p_item_type
  and    NAME = p_attribute_name;
Line: 3868

  select DISPLAY_NAME,
         DESCRIPTION,
         TYPE,
         RERUN,
         PROTECT_LEVEL,
         CUSTOM_LEVEL,
         BEGIN_DATE,
         FUNCTION,
         FUNCTION_TYPE,
         RESULT_TYPE,
         COST,
         READ_ROLE,
         WRITE_ROLE,
         EXECUTE_ROLE,
         ICON_NAME,
         MESSAGE,
         ERROR_PROCESS,
         EXPAND_ROLE,
         ERROR_ITEM_TYPE,
         RUNNABLE_FLAG,
         VERSION
  into   p_display_name,
         p_description,
         p_type,
         p_rerun,
         p_protect_level,
         p_custom_level,
         p_begin_date,
         p_function,
         p_function_type,
         p_result_type,
         p_cost,
         p_read_role,
         p_write_role,
         p_execute_role,
         p_icon_name,
         p_message,
         p_error_process,
         p_expand_role,
         p_error_item_type,
         p_runnable_flag,
         p_version
  from   WF_ACTIVITIES_VL
  where  ITEM_TYPE = p_item_type
  and    NAME = p_name
  and    END_DATE is null;
Line: 3934

procedure UPDATE_ACTIVITY (
  p_item_type in varchar2,
  p_name in varchar2,
  p_display_name in varchar2,
  p_description in varchar2 ,
  p_expand_role in varchar2 ,
  p_level_error out NOCOPY number)
is
  conflict_name       varchar2(240);
Line: 4014

      Wf_Core.Context('Wf_Load', 'Update_Activity Get_Activity');
Line: 4035

    select ITEM_TYPE||':'||NAME||':'||to_char(VERSION), DISPLAY_NAME, NAME
    into conflict_name, l_dname, l_name
    from WF_ACTIVITIES_VL
    where DISPLAY_NAME = n_dname
    and ITEM_TYPE = p_item_type
    and l_begin_date >= BEGIN_DATE
    and l_begin_date < nvl(END_DATE, l_begin_date+1)
    and NAME <> p_name;
Line: 4049

        select ITEM_TYPE||':'||NAME||':'||to_char(VERSION), DISPLAY_NAME
        into conflict_name, l_dname
        from WF_ACTIVITIES_VL
        where DISPLAY_NAME = n_dname
        and ITEM_TYPE = p_item_type
        and l_begin_date >= BEGIN_DATE
        and l_begin_date < nvl(END_DATE, l_begin_date+1)
        and NAME <> l_name;
Line: 4082

  update  WF_ACTIVITIES
  set     expand_role = l_expand_role
  where   ITEM_TYPE = p_item_type
  and     NAME = p_name
  and     VERSION = l_version;
Line: 4088

  update  WF_ACTIVITIES_TL
  set     DISPLAY_NAME = n_dname,
          DESCRIPTION  = l_description
  where   ITEM_TYPE = p_item_type
  and     NAME = p_name
  and     VERSION = l_version;
Line: 4097

    Wf_Core.Context('Wf_Load', 'Update_Activity', p_item_type, p_name,
                    p_display_name);
Line: 4132

    select INSTANCE_ID into id
    from   WF_PROCESS_ACTIVITIES
    where  INSTANCE_LABEL = p_instance_label
    and    PROCESS_NAME = p_process_name
    and    PROCESS_ITEM_TYPE = p_process_item_type
    and    PROCESS_VERSION = p_process_version;
Line: 4143

  select INSTANCE_ID into id
  from   WF_PROCESS_ACTIVITIES
  where  PROCESS_NAME = p_process_name
  and    PROCESS_ITEM_TYPE = p_process_item_type
  and    PROCESS_VERSION = p_process_version
  and    ACTIVITY_ITEM_TYPE = p_activity_item_type
  and    ACTIVITY_NAME = p_activity_name
  and    rownum = 1;
Line: 4175

  select ACTIVITY_NAME
  into   l_actname
  from   WF_PROCESS_ACTIVITIES
  where  INSTANCE_ID = p_instance_id;
Line: 4213

  select RESULT_CODE
  from   WF_ACTIVITY_TRANSITIONS
  where  FROM_PROCESS_ACTIVITY = from_act
  and    TO_PROCESS_ACTIVITY = to_act;
Line: 4219

  select TO_PROCESS_ACTIVITY
  from   WF_ACTIVITY_TRANSITIONS
  where  FROM_PROCESS_ACTIVITY = from_act
  and    RESULT_CODE = res_code;
Line: 4225

  select TO_PROCESS_ACTIVITY, RESULT_CODE
  from   WF_ACTIVITY_TRANSITIONS
  where  FROM_PROCESS_ACTIVITY = from_act;
Line: 4230

  select FROM_PROCESS_ACTIVITY
  from   WF_ACTIVITY_TRANSITIONS
  where  TO_PROCESS_ACTIVITY = to_act
  and    RESULT_CODE = res_code;
Line: 4236

  select FROM_PROCESS_ACTIVITY, RESULT_CODE
  from   WF_ACTIVITY_TRANSITIONS
  where  TO_PROCESS_ACTIVITY = to_act;
Line: 4305

  select NAME
  from   WF_ITEM_ATTRIBUTES
  where  ITEM_TYPE = p_item_type
  and    NAME like '%'||p_suffix;
Line: 4339

  select NAME
  from   WF_ACTIVITIES
  where  NAME like '%'||p_suffix
  and    ITEM_TYPE = p_item_type
  and    TYPE = 'NOTICE'
  and    END_DATE is null;
Line: 4374

  select NAME
  from   WF_MESSAGES
  where  NAME like '%'||p_suffix
  and    TYPE = p_item_type;
Line: 4409

  select INSTANCE_ID
  from   WF_PROCESS_ACTIVITIES
  where  PROCESS_NAME = p_process_name
  and    PROCESS_ITEM_TYPE = p_process_item_type
  and    PROCESS_VERSION   = p_process_version;
Line: 4451

  select MEANING, DESCRIPTION, PROTECT_LEVEL, CUSTOM_LEVEL
  into   x_meaning, x_description, x_protect_level, x_custom_level
  from   WF_LOOKUPS
  where  LOOKUP_TYPE = x_lookup_type
  and    LOOKUP_CODE = x_lookup_code;
Line: 4478

procedure UPDATE_LOOKUP(
  x_lookup_type       in varchar2,
  x_lookup_code       in varchar2,
  x_meaning           in varchar2 ,
  x_description       in varchar2 ,
  x_protect_level     in number ,
  x_custom_level      in number ,
  x_level_error       out NOCOPY number
)
is
  l_meaning       varchar2(80);
Line: 4524

    Wf_Core.Context('Wf_Load', 'Update_Lookup', x_lookup_type, x_lookup_code);
Line: 4542

  select LOOKUP_CODE
  from   WF_LOOKUPS
  where  LOOKUP_TYPE = p_lookup_type;
Line: 4585

  select WPA.ACTIVITY_ITEM_TYPE, WPA.ACTIVITY_NAME
  from   WF_PROCESS_ACTIVITIES WPA,
         WF_ACTIVITIES WA
  where  WPA.PROCESS_ITEM_TYPE = p_process_item_type
  and    WPA.PROCESS_NAME = p_process_name
  and    WPA.PROCESS_VERSION = ver
  and    WPA.ACTIVITY_ITEM_TYPE = WA.ITEM_TYPE
  and    WPA.ACTIVITY_NAME = WA.NAME
  and    WA.TYPE = 'PROCESS'
  and    active_date >= WA.BEGIN_DATE
  and    active_date < nvl(WA.END_DATE, active_date+1);
Line: 4610

    select VERSION into m_version
    from   WF_ACTIVITIES
    where  ITEM_TYPE = p_process_item_type
    and    NAME = p_process_name
    and    active_date >= BEGIN_DATE
    and    active_date <  nvl(END_DATE, active_date + 1);
Line: 4626

  select count(1) into n
  from   WF_PROCESS_ACTIVITIES
  where  PROCESS_ITEM_TYPE = p_process_item_type
  and    PROCESS_NAME = p_process_name
  and    PROCESS_VERSION = m_version
  and    ACTIVITY_ITEM_TYPE = nvl(p_activity_item_type, p_process_item_type)
  and    ACTIVITY_NAME = p_activity_name;