Ejemplo n.º 1
0
        public SQLBuilder Select(params SQLParameter[] parameters)
        {
            var formatter = new SQLParameterFormatter(parameters);

            formatter.Execute();

            command.Parameters  = parameters.Select(p => p.Parameter).ToArray();
            command.CommandText = string.Concat(formatter.Result, command.CommandText);

            return(this);
        }
Ejemplo n.º 2
0
        public SQLBuilder Select(IEnumerable <SQLParameter> parameters)
        {
            var @params = parameters.ToList();

            var formatter = new SQLParameterFormatter(@params);

            formatter.Execute();

            command.Parameters  = @params.Select(p => p.Parameter).ToArray();
            command.CommandText = string.Concat(formatter.Result, command.CommandText);

            return(this);
        }