过程改成表值函数返回列表
--DECLARE--B A;select *from table(cast(B as A))create or replace type CTest as object(tid varchar2(6),tname varchar2(20))/create or replace type tabCtest is table of cTest/create or replace function myTest return tabctestis Result tabctest := tabctest();begin Result := tabctest(); Result.extend; Result(Result.count) := CTEST(NULL,NULL); Result(Result.count).tid := '1'; Result(Result.count).tname := 'name1'; Result.extend; Result(Result.count) := CTEST(NULL,NULL); Result(Result.count).tid := '2'; Result(Result.count).tname := 'name2'; return(Result);end myTest;/select *from table(cast(myTest as tabctest))