Esempio n. 1
0
        public void SetParameter(ParameterDirection direction, DbType dbType,
                                 string param, object value)
        {
            ParameterClause parameter = new ParameterClause(direction, dbType, param, value);

            parameters.Add(parameter);
        }
Esempio n. 2
0
        private DbParameter CreateDbParameter(DbCommand cmd, ParameterClause param)
        {
            DbParameter sqlParam = cmd.CreateParameter();

            sqlParam.ParameterName = param.Name;
            sqlParam.DbType        = param.DbType;
            sqlParam.Value         = ReferenceEquals(param.Argument, null) ? DBNull.Value : param.Argument;
            sqlParam.Direction     = param.Direction;
            sqlParam.FixParameterRange();

            return(sqlParam);
        }
Esempio n. 3
0
        public void SetParameter(string param, DbType dbType, object value)
        {
            ParameterClause parameter = new ParameterClause(param, dbType, value);

            parameters.Add(parameter);
        }