MAKE_REF and ORA-22979
Using the MAKE_REF function to create a REF to a row of an object table whose object identifier is primary key based, I continue to receive error ORA-22979. For example:
CREATE OR REPLACE TYPE child_menu_type AS OBJECT (
menu_option_id REF VAL_MENU_OPTIONS_TYPE)
FINAL INSTANTIABLE;
/
CREATE OR REPLACE TYPE child_menu_table_type AS TABLE OF child_menu_type;
/
CREATE OR REPLACE TYPE val_menu_assoc_type AS OBJECT (
menu_option_id NUMBER(4),
child_menus CHILD_MENU_TABLE_TYPE)
FINAL INSTANTIABLE;
/
CREATE TABLE val_menu_assoc OF val_menu_assoc_type (
CONSTRAINT xpk_vma PRIMARY KEY (menu_option_id))
OBJECT IDENTIFIER IS PRIMARY KEY
NESTED TABLE child_menus STORE AS child_menus_nt;
INSERT INTO val_menu_assoc VALUES
(0,
CHILD_MENU_TABLE_TYPE
(CHILD_MENU_TYPE
(MAKE_REF(val_menu_options,5)
)
)
);
According to the documentation, this should've worked. It did not. The error persists.