public IEnumerable <T> QueryStoredProcedure <T>(string procedureName, params StoreParameter[] parameters) { var procBuilder = new StoredProcedureBuilder(procedureName, DataContext); procBuilder.AddParameters(parameters); return(DataContext.Query <T>(procBuilder.Build())); }
public T SingleStoredProcedure <T>(string procedureName, params StoreParameter[] parameters) { var procBuilder = new StoredProcedureBuilder(procedureName, DataContext); procBuilder.AddParameters(parameters); return(DataContext.SingleOrDefault <T>(procBuilder.Build())); }
public int ExecuteStoredProcedure(string procedureName, params StoreParameter[] parameters) { var procBuilder = new StoredProcedureBuilder(procedureName, DataContext); procBuilder.AddParameters(parameters); var _sql = procBuilder.Build(); return(DataContext.Execute(_sql.SQL, CommandType.StoredProcedure, _sql.Arguments)); }
public DataTable QueryStoredProcedure(string procedureName, params StoreParameter[] parameters) { var procBuilder = new StoredProcedureBuilder(procedureName, DataContext); procBuilder.AddParameters(parameters); var sql = procBuilder.Build(); var items = DataContext.Fetch <Dictionary <string, object> >(sql); return(items.ToDataTable()); }