Suppose I have some data types defined in PL/SQL:
TYPE foo_t IS RECORD (...);
TYPE foo_table_t IS TABLE OF foo_t INDEX BY BINARY_INTEGER;
TYPE bar_t IS RECORD (...);
TYPE bar_table_t IS TABLE OF bar_t INDEX BY BINARY_INTEGER;
Is it possible for me to write a procedure capable of accepting any data type derived from TABLE (for example, either a foo_table_t
or a bar_table_t
) as a parameter? The procedure has no need for knowledge of the table's row types. A trivial example:
PROCEDURE remove_last(some_table ...) IS
BEGIN
some_table.DELETE(some_table.LAST);
END;