Adrian Io 17.Aug.12 02:03 PM a Web browser LC LSXAll ReleasesWindows
I want to use an lotus agent to call a Oracle stored procedure who insert a value in oracle table but is not working. From Lotus agent i have connection to oracle database.
What is wrong in the script ?
The stored procedure is like this :
create or replace procedure "ARHIVA_TEST"
(p_uid IN VARCHAR2)
is
begin
INSERT INTO AUX_LOG_ARHIVA ("ID")
VALUES (p_uid);
end;
Lotus agent is like this:
Uselsx "*LSXODBC"
Uselsx "*LSXLC"
Sub Initialize
Dim Con As New LCConnection ("odbc2")
Dim Parms As New LCFieldList
Dim Result As New LCFieldList
Dim Parm As LCField
' set properties to connect to both data sources
Con.Server = "LOTUS"
Con.Userid = "system"
Con.Password = "12345"
' set the connection property to the stored procedure name
Con.Procedure = "ARHIVA_TEST"
' now connect
Con.Connect
' append the new field to the fieldlist
Set Parm = Parms.Append ("p_uid", LCTYPE_TEXT)
' set the field to a value -- in this case it is
' the one parameter needed for the stored procedure
Parm.text = " '1' "
' using the fieldlist containing the field with the
' stored procedure parameter, call the stored procedure