public SqlEntityMatchingFieldsReader(InputContext input) { var tempTable = input.Entity.GetExcelName(); _keys = input.Entity.GetPrimaryKey(); _input = input; _create = SqlCreateKeysTable(input, tempTable); _insert = SqlInsertTemplate(input, tempTable); _query = SqlQuery(input, tempTable); _drop = SqlDrop(input, tempTable); _rowCreator = new SqlRowCreator(input); }
public SqlReader(IContext context, Field[] fields, ReadFrom readFrom) { _context = context; _connection = readFrom == ReadFrom.Output ? context.Process.Connections.First(c => c.Name == "output") : context.Process.Connections.First(c => c.Name == context.Entity.Connection); _tableOrView = readFrom == ReadFrom.Output ? context.Entity.OutputTableName(context.Process.Name) : context.Entity.Name; _fields = fields; _readFrom = readFrom; _rowCreator = new SqlRowCreator(context); }
public SqlEntityMatchingKeysReader(IConnectionContext context, Field[] keys) { var tempTable = context.Entity.GetExcelName(); _context = context; _keys = keys; _rowCapacity = context.GetAllEntityFields().Count(); _hashCode = context.Entity.TflHashCode(); _fields = CombineFields(keys, _hashCode); _create = SqlCreateKeysTable(context, tempTable); _insert = SqlInsertTemplate(context, tempTable, keys); _query = SqlQuery(keys, context, tempTable, _hashCode); _drop = SqlDrop(context, tempTable); _rowCreator = new SqlRowCreator(context); }
public SqlStarParametersReader(OutputContext output, Process process) { _output = output; _process = process; _rowCreator = new SqlRowCreator(output); }
public SqlInputReader(InputContext input, Field[] fields) { _input = input; _fields = fields; _rowCreator = new SqlRowCreator(input); }