我正在尝试使用此c#代码从oracle执行存储过程:
string extension = Filename_Box.Text.Substring(Filename_Box.Text.IndexOf('.'));
string package_query = "";
//Run the appropriate package/procedure for the file
switch(extension)
{
case ".400":
case ".500":
case ".901":
case ".301":
case ".303":
//Just for testing, remove for production
package_query = @"CREDIT_CARD.READ_ECI_CC";
//package_query = @"INTERFACE.CREDIT_CARD.READ_ECI_CC";
break;
case ".200":
package_query = @"CREDIT_CARD.READ_ECI_NEWFORMAT_CC";
//package_query = @"INTERFACE.CREDIT_CARD.READ_ECI_NEWFORMAT_CC";
break;
case ".DAT":
package_query = @"CREDIT_CARD.READ_INSPRO_CC";
//package_query = @"INTERFACE.CREDIT_CARD.READ_INSPRO_CC";
break;
default:
break;
}
using (OracleConnection package_connection = new OracleConnection(connection_string))
{
OracleCommand package_command = package_connection.CreateCommand();
package_command.CommandText = package_query;
package_command.CommandType = System.Data.CommandType.StoredProcedure;
package_command.Parameters.Add("p_filename", OracleDbType.Varchar2).Value = Filename_Box.Text;
try
{
package_connection.Open();
package_command.ExecuteNonQuery();
}
此错误消息的含义是什么?如何解决? 详细的错误消息如下:
Oracle.ManagedDataAccess.Client.OracleException(0x00007263): ORA-29283:文件操作无效ORA-06512:at" SYS.UTL_FILE&#34 ;, line 475 ORA-29283:文件操作无效ORA-06512:at " ACANZONE.CREDIT_CARD",第530行ORA-06512:第1行 OracleInternal.ServiceObjects.OracleCommandImpl.VerifyExecution(OracleConnectionImpl connectionImpl,Int32& cursorId,Boolean bThrowArrayBindRelatedErrors, OracleException&安培; exceptionForArrayBindDML,Boolean& hasMoreRowsInDB, Boolean bFirstIterationDone)at OracleInternal.ServiceObjects.OracleCommandImpl.VerifyExecution(OracleConnectionImpl connectionImpl,Int32& cursorId,Boolean bThrowArrayBindRelatedErrors, OracleException&安培; exceptionForArrayBindDML,Boolean bFirstIterationDone)at OracleInternal.ServiceObjects.OracleCommandImpl.ExecuteNonQuery(字符串 commandText,OracleParameterCollection paramColl,CommandType commandType,OracleConnectionImpl connectionImpl,Int32 longFetchSize, Int32 lobPrefetchSize,OracleDependencyImpl orclDependencyImpl, 的Int64 []&安培; scnFromExecution,OracleParameterCollection& bindByPositionParamColl,Boolean& bBindParamPresent,Boolean isFromEF) 在Oracle.ManagedDataAccess.Client.OracleCommand.ExecuteNonQuery()at Credit_Card_Processing.MainWindow.search_button_Click(对象发送者, RoutedEventArgs e)in X:\ GIT_REPOS \ C_SHARP_CODE \ USER_INTERFACES \ Credit_Card_Processing \ MainWindow.xaml.cs:行 157