Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Can I do external procedure calls with Personal Oracle 8.1.7 - it doesn't work

Can I do external procedure calls with Personal Oracle 8.1.7 - it doesn't work

From: brian <brian.pacitti_at_btinternet.com>
Date: Thu, 4 Jul 2002 22:34:15 +0000 (UTC)
Message-ID: <ag2ih6$h0t$1@paris.btinternet.com>


Hi there,

I am trying to run an external DLL from within PL/SQL and am getting an ora-28575 error. I am running Personal Oracle 8.1.7 on Windows 98.

I have read the copious number of posts on the subject and my tnsnames.ora, listener.ora and sqlnet.ora appear to be set up correctly. In any case this is a new installation of Personal Oracle 8.1.7 and the .ora configurations for external procedure calls is done automatically on installation. Also I can run the extproc.exe from MS-DOS.

I am testing this by trying to call a windows function from one of the standard windows DLLs but am getting an ora-28575. This is what I am doing:

CREATE OR REPLACE LIBRARY dlltest_library AS 'c:\windows\system\advapi32.dll' ;
/

CREATE OR REPLACE function dlltest_function (V IN OUT VARCHAR2, W IN OUT long) return boolean AS
external name "GetUserNameA" library dlltest_library;
/

declare

  lb_rtn boolean;
  ls_username varchar2(30);
  ll_length   long;

BEGIN
  ll_length := 255;
  ls_username := ' ';
  lb_rtn := dlltest_function (ls_username, ll_length   );
  dbms_output.put_line('username = '||ls_username); END;
/

Is there any other configuration I must do (parameter in the init.ora for example) to get this to work ?

I never had much hair before I started this task anyway !!

Any help would be much appreciated although I guess I am asking the same question as a number of other posts.

Thanks
Brian Received on Thu Jul 04 2002 - 17:34:15 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US