External C call gives ORA-28595
272297Jun 13 2003 — edited Jun 16 2003Hi -
I have been trying to get C external procedure calls working. I adapted an example on TechNet as follows:
create library externProcedures as 'C:\ORA9_2\RDBMS\EXTPROC\extern.dll';
/
CREATE OR REPLACE FUNCTION PLS_MAX(
x BINARY_INTEGER,
y BINARY_INTEGER)
RETURN BINARY_INTEGER AS
LANGUAGE C
NAME "find_max"
LIBRARY externProcedures
PARAMETERS (
x long,
x INDICATOR short,
y long,
y INDICATOR short,
RETURN INDICATOR short );
/
CREATE OR REPLACE PROCEDURE UseIt AS
a integer;
b integer;
c integer;
BEGIN
a := 1;
b := 2;
c := PLS_MAX(a,b);
dbms_output.put_line('The maximum of '||a||' and '||b||' is '||c);
END;
/
exec UseIt
Everything compiles and is valid. The C compile and link appears to work fine. But I get:
ORA-28595: Extproc agent : Invalid DLL Path
I can't find any reference to this exception at all. Any ideas?
B.