Erro do Oracle ORA-22905: não é possível acessar linhas de um item de tabela não aninhado
aqui está o procedimento armazenado que escrevi.Neste processo, "p_subjectid" é uma matriz de números passados do front-en
PROCEDURE getsubjects(p_subjectid subjectid_tab,p_subjects out refCursor)
as
BEGIN
open p_subjects for select * from empsubject where subject_id in
(select column_value from table(p_subjectid));
--select * from table(cast(p_subjectid as packg.subjectid_tab))
END getsubjects;
Este é o erro que estou recebendo.
Oracle error ORA-22905: cannot access rows from a non-nested table item OR
Como eu já vi em post diferente, tentei lançar "cast (p_subjectid como packg.subjectid_tab)" dentro da função da tabela, conforme fornecido no comentário abaixo. Mas estou recebendo outro erro:ORA-00902: invalid datatype
.
E esta é a definição do "subjectid_tab".
type subjectid_tab is table of number index by binary_integer;
Alguém pode me dizer qual é o erro. Há algo errado com o meu procediment