コード例 #1
0
        public static void executeNonQuery(string spName, ArrayList alParametros)
        {
            OracleConnection connection = OracleDAC.getConnection();
            OracleCommand    command    = OracleDAC.getCommand(connection, spName, alParametros);

            command.CommandType = CommandType.StoredProcedure;
            command.ExecuteNonQuery();
            OracleDAC.closeConnection(connection);
        }
コード例 #2
0
        public static object executeScalar(string sql, ArrayList alParametros)
        {
            OracleConnection connection = OracleDAC.getConnection();
            OracleCommand    command    = OracleDAC.getCommand(connection, sql, alParametros);

            command.CommandType = CommandType.Text;
            object obj = command.ExecuteScalar();

            OracleDAC.closeConnection(connection);
            return(obj);
        }
コード例 #3
0
        public static DataSet getDataset(string sql)
        {
            OracleConnection connection = OracleDAC.getConnection();
            OracleCommand    command    = OracleDAC.getCommand(connection, sql);

            command.CommandType = CommandType.Text;
            OracleDataAdapter oracleDataAdapter = new OracleDataAdapter(command);
            DataSet           dataSet           = new DataSet();

            ((DataAdapter)oracleDataAdapter).Fill(dataSet);
            OracleDAC.closeConnection(connection);
            return(dataSet);
        }
コード例 #4
0
        public static DataSet getDataset(string spName, ArrayList alParametros)
        {
            OracleConnection connection = OracleDAC.getConnection();
            OracleCommand    command    = OracleDAC.getCommand(connection, spName, alParametros);

            command.CommandType = CommandType.StoredProcedure;
            OracleDataAdapter oracleDataAdapter = new OracleDataAdapter(command);
            DataSet           dataSet           = new DataSet();

            ((DataAdapter)oracleDataAdapter).Fill(dataSet);
            OracleDAC.closeConnection(connection);
            return(dataSet);
        }