Hi,
“HTTP JVM: java.lang.UnsatisfiedLinkError: Can’t find library ocijdbc9 (ocijdbc9.dll) in java.library.path.” -
this is the error I get trying to run Java agent that envokes oracle stored procedure. It was writen a few years ago (http://www-10.lotus.com/ldd/46dom.nsf/55c38d716d632d9b8525689b005ba1c0/9badc27cc1d0429485256bf2003d8b6c?OpenDocument)
and worked fine till now on Domino 5 and Oracle 8. Now we moved to Domino 6.5 and Oracle 9 and it fails saying:
HTTP JVM: java.lang.UnsatisfiedLinkError: Can’t find library ocijdbc9 (ocijdbc9.dll) in java.library.path java.library.path=C:\Lotus\Domino;.;C:\WINDOWS\system32;C:\WINDOWS;c:\oracle\ora92\bin;C:\oracle\ora92\lib;C:\IBM\MQseries\Java\lib;c:\oracle\ora92\jre\1.4.2\bin\client;c:\oracle\ora92\jre\1.4.2\bin;C:\Program Files\Oracle\jre\1.3.1\bin;C:\Program Files\Oracle\jre\1.1.8\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\IBM\Director\bin;C:\Program Files\BCN=lotustest1/O=Mehish
on this row:
Connection conn = DriverManager.getConnection (“jdbc:oracle:oci8:@dbc-name”, “user”, “password”);
despite of fact that ocijdbc9.dll exist under c:\oracle\ora92\bin and Domino service user has full rights on that folder. Copying of that dll to Domino folder or to windows/system32 folder just crash the server at the agent run.
On the other hand simple Java program with same contents like the agent works fine when runned by java.exe located under: C:\Lotus\Domino\jvm\bin (same one that runs the agent, right?).
I also tried to mix Lotus Script with Java (LS2J) and wrote an agent that use that simple Java program that worked before, but guess what happened?! Right - when Java program reached that problematic “getConnection” row - it failed again with the same error!!!
Please advise how to make it work.
Thank you,
Y.M.
P.S. I also tried to move back to Lotus Script stored procedure calls - nothing. Just error msgs saying “PLS-00306: wrong number or types of arguments in call to ‘PROC_NAME’”.
I have to pass one text param and get back two and I did it like this:
Dim session As New NotesSession
Dim sesslc As New LCSession
Dim src As New LCConnection (“oracle8”)
Dim fieldsIn As New LCFieldList
Dim fieldsOut As New LCFieldList
Dim fieldIn As New LCField (1, LCTYPE_TEXT)
Dim fieldOut1 As New LCField (1, LCTYPE_TEXT)
Dim fieldOut2 As New LCField (1, LCTYPE_TEXT)
Dim Count As Long
sesslc.ClearStatus
src.server = “server”
src.Userid = “user”
src.Password = “pwrd”
src.Procedure = “DBATEAM.SESSIONS_MANAGEMENT.GETID”
src.connect
Set fieldIn = fieldsIn.Append(“in1”, LCTYPE_TEXT)
fieldIn.text = “‘1234567’”
'i have tried next rows instead of the previous one as well
'fieldIn.text = “1234567”
'fieldIn.value = “1234567”
Call fieldsIn.Append(“out1”, LCTYPE_TEXT)
Call fieldsIn.Append(“out2”, LCTYPE_TEXT)
Print “Calling the stored procedure…”
If (src.Call(fieldsIn, 1, fieldsOut) = 0) Then
Print “Stored Procedure called successfully.”
Set fieldOut1 = fieldsOut.GetField(1)
Set fieldOut2 = fieldsOut.GetField(2)
Call src.Fetch(fieldsOut)
Print "The retrieved Name is: " & fieldOut1.value
Print "The retrieved timestamp is: " & fieldOut2.value
Else
Print “There was an error running the Stored Procedure”
End If
src.Disconnect