How to call DB Functions in VB.NET
Hi All.....
I am very new to .net and my first proj is for a PDA..... I have installed Oracle Client... However the command seems to be quite different from the others...
I am trying to call a database function.
My code is as follows:
Dim cmd1 As LiteCommand = con.CreateCommand()
cmd1.CommandText = "fncEncryptPsswd"
cmd1.CommandType = CommandType.StoredProcedure
Dim p1 As New OracleParameter("p_input1", DbType.String)
p1.Value = UCase(Trim(txtPsword.Text))
p1.Direction = ParameterDirection.Input
cmd1.Parameters.Add(p1)
Dim p2 As New OracleParameter("output1", DbType.String)
p2.Direction = ParameterDirection.ReturnValue
cmd1.Parameters.Add(p2)
cmd1.ExecuteNonQuery()
con.Close()
It throws the error:
37000[POL- 5228] syntax error
Any help in this regard is highly appreciated.
Regards...
Rinjin