Hi!
Test script:
create table list_hash_tab(
id number,
code varchar2(10),
description varchar2(50),
created_date date
)
partition by list(code)
subpartition by hash(id)
(partition part_aa values('AA')(subpartition part_aa_01,
subpartition part\_aa\_02
),
partition part_bb values ('BB')
(
subpartition part\_bb\_01,
subpartition part\_bb\_02
)
);
/
declare
l_code varchar2(10);
begin
for i in 1 .. 40 loop
if mod(i, 2) = 0 then
l\_code := 'BB';
else
l\_code := 'AA';
end if;
insert into list\_hash\_tab (id, code, description, created\_date)
values (i, l\_code, 'Description for ' || i || ' ' || l\_code, sysdate);
end loop;
commit;
end;
/
create or replace package partition_test
as
procedure prc\_test;
end partition_test;
/
create or replace package body partition_test
as
procedure prc_test
is
p_obj_id number;
list_ro list_hash_tab.id%type;
begin
select object_id into p_obj_id from user_objects where subobject_name = 'PART_AA_01';
select id into list_row from list_hash_tab subpartition(dataobj_to_partition(list_hash_tab, p_obj_id));
prc_tes end partition_test;
/
If we open package and Code Outline then(package is valid)
