Initially I needed to create a procedure that read an xml file and put the data into an oracle table, create the table, the directory, I have the following structure:
create or replace package body PACK_GUSTAVO1 as
v_id INFO_XML.ID%type;
cursor C1 is SELECT NVL(MAX(ID)+1,1) AS ID FROM INFO_XML;
PROCEDURE IMPORTA_XML IS
BEGIN
/* ABRE CURSOR */
OPEN C1;
LOOP
/* LÊ UM REGISTRO DO CURSOR */
fetch C1 into v_id;
/* ABANDONA O LOOP CASO SEJA O FINAL DO CURSOR */
EXIT WHEN C1%NOTFOUND;
END LOOP;
/* FECHA O CURSOR */
CLOSE C1;
DBMS_OUTPUT.PUT_LINE('proximo:' || v_id);
DELETE FROM INFO_XML WHERE ID=v_id;
COMMIT;
INSERT INTO INFO_XML (ID, CONTEUDO) VALUES
(v_id, XMLTYPE(BFILENAME('CARGA_CSV', 'funcionarios.xml'), NLS_CHARSET_ID('WE8ISO8859P1')));
COMMIT;
/* grava na tabela */
END;
end PACK_GUSTAVO1;
and my select extract value:
SELECT extractValue(CONTEUDO, '/funcionarios/contato/nome/value') as NOME FROM INFO_XML;
But it is giving error, I do not know what to do.