forked from ddrilling/AsbCloudServer
Merge branch 'master' of https://bitbucket.org/autodrilling/asbcloudserver
This commit is contained in:
commit
c0a4716341
@ -385,23 +385,22 @@ namespace AsbCloudDb.Model
|
||||
Database.OpenConnection();
|
||||
using var reader = await command.ExecuteReaderAsync(token);
|
||||
|
||||
IEnumerable<(double? MinDepth, double? MaxDepth, DateTime BeginPeriodDate)> GetResult(DbDataReader rd)
|
||||
var result = new List<(double? MinDepth, double? MaxDepth, DateTime BeginPeriodDate)>();
|
||||
|
||||
if (reader.HasRows)
|
||||
{
|
||||
if (rd.HasRows)
|
||||
while (reader.Read())
|
||||
{
|
||||
while (reader.Read())
|
||||
{
|
||||
yield return
|
||||
(
|
||||
(double?)reader.GetValue(0),
|
||||
(double?)reader.GetValue(1),
|
||||
(DateTime)reader.GetValue(2)
|
||||
);
|
||||
}
|
||||
result.Add(
|
||||
(
|
||||
(double?)reader.GetValue(0),
|
||||
(double?)reader.GetValue(1),
|
||||
(DateTime)reader.GetValue(2)
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
return GetResult(reader);
|
||||
return result;
|
||||
}
|
||||
|
||||
public async Task<int> CreatePartitionAsync<TEntity>(string propertyName, int id, CancellationToken token = default)
|
||||
|
Loading…
Reference in New Issue
Block a user