答案是这样。您不能使用全局创建的或架构级别的类型作为存储过程的参数。PHP的oci_bind_array_by_name似乎不适用于全局创建的类型,但是您需要全局创建的类型才能将数组用作子选择中的嵌套表。所以....这就是我如何使它工作的。我非常高兴听到其他解决方案!!但是现在,这就是我所做的。
-- globally create a type table of numbercreate or replace type num_array is table of number;-- in my package i created an internal type table of numbertype i_num_array is table of number index by binary_integer;-- i then used i_num_array (internal type) as the type for my IN parameter to the procedureupsert_TXA_compliance_slct( v_compl_id_array in i_num_array)-- in my procedure i also created a variable that is the type of my globally created typev_num_array num_array := num_array();-- then i populated that variable in a loop inside my procedure with the values in my IN paramfor i in 1 .. v_compl_id_array.countloop v_num_array.extend(1); v_num_array(i) := v_compl_id_array(i);end loop;-- then i used v_num_array as my nested table so this now works:delete from my_table where id in (select * from table(v_num_array));



