Пример #1
0
            protected override DbDataReader ExecuteReader(DbCommand command)
            {
                DbDataReader reader = new VfpDataReader(command.ExecuteReader(), this.provider.AutoRightTrimStrings);

                if (this.BufferResultRows)
                {
                    // use data table to buffer results
                    var ds = new DataSet();
                    ds.EnforceConstraints = false;
                    var table = new DataTable();
                    ds.Tables.Add(table);
                    ds.EnforceConstraints = false;
                    table.Load(reader);
                    reader = table.CreateDataReader();
                }
                return(reader);
            }
Пример #2
0
            protected override IEnumerable <T> Project <T>(DbDataReader reader, Func <FieldReader, T> fnProjector, MappingEntity entity, bool closeReader)
            {
                VfpDataReader vfpDataReader = new VfpDataReader(reader, this.provider.AutoRightTrimStrings);

                return(base.Project <T>(vfpDataReader, fnProjector, entity, closeReader));
            }