public async Task <List <IDataModel> > readResultFromRequest(SqlCommand command, string expectedType) { var reader = await command.ExecuteReaderAsync(); var rows = new List <IDataModel>(); IDataModel row = MapStringToModelType(expectedType); while (reader.Read()) { row = row.MapToModel(reader); rows.Add(row); } return(rows); }