Main Tables Views Indexes Constraints Triggers Procedures Functions Packages Sanity check Index

ACS3 Data Model

Arguments Source

APM_INSURE_PACKAGE_ENABLED

Arguments:

NameData TypeDefault ValueIn/Out
V_PACKAGE_KEYVARCHAR2 IN

Source

Source
     1: procedure apm_insure_package_enabled(v_package_key in varchar) is
     2:     cursor cur is
     3:         select v.rowid
     4:         from   apm_package_versions v, apm_packages p
     5:         where  v.package_id = p.package_id
     6:         and    p.package_key = v_package_key
     7:         order by apm_version_order(version_name) desc
     8:         for update of enabled_p;
     9:     a_rowid rowid;
    10:     a_count integer;
    11: begin
    12:     select count(*) into a_count
    13:     from   apm_enabled_package_versions
    14:     where  package_key = v_package_key;
    15: 
    16:     if a_count = 0 then
    17:         open cur;
    18:         fetch cur into a_rowid;
    19:         if not cur%notfound then
    20:             update apm_package_versions set enabled_p = 't' where current of cur;
    21:             return;
    22:         end if;
    23:     end if;
    24: end;


Generated by OraSchemaDoc, (c) Aram Kananov, 2002