A
Andy
How to find out or catch compiler error during scripting stored procedure
via OracleCommand class?
E.g.
OracleCommand _oracleCommand = new OracleCommand();
.......
StringBuilder sb = new StringBuilder();
sb.AppendLine("create or replace procedure test_proc(var_number in
number) as");
sb.AppendLine("begin");
sb.AppendLine(" insert into test_table (data) values (var_number);");
sb.AppendLine(" any wrong code;");
sb.AppendLine("end;");
_oracleCommand.CommandText = sb.ToString();
_oracleCommand.Connection.Open();
_oracleCommand.ExecuteNonQuery();
_oracleCommand.Connection.Close();
ADO .NET throws no exception, bu stored procedure is not valid. Is any
solution?
TIA
via OracleCommand class?
E.g.
OracleCommand _oracleCommand = new OracleCommand();
.......
StringBuilder sb = new StringBuilder();
sb.AppendLine("create or replace procedure test_proc(var_number in
number) as");
sb.AppendLine("begin");
sb.AppendLine(" insert into test_table (data) values (var_number);");
sb.AppendLine(" any wrong code;");
sb.AppendLine("end;");
_oracleCommand.CommandText = sb.ToString();
_oracleCommand.Connection.Open();
_oracleCommand.ExecuteNonQuery();
_oracleCommand.Connection.Close();
ADO .NET throws no exception, bu stored procedure is not valid. Is any
solution?
TIA