Skip to content
This repository was archived by the owner on Feb 1, 2025. It is now read-only.

Commit b9e0832

Browse files
authored
Removed mentioning additional async methods.
We have implemented IAsyncQueryProvider, so EF async functions should work as expected.
1 parent 94243d1 commit b9e0832

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

README.md

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,7 @@ using (var dc = options.CreateLinqToDbConnection())
8080
}
8181
```
8282

83-
You can use all `LINQ To DB` extension functions in your EF linq queries. Just ensure you have called `ToLinqToDB()` function before materializing objects for synchronous methods.
84-
85-
Since EF Core have defined it's own asynchronous methods, we have to duplicate them to avoid naming collisions.
86-
Async methods have the same name but with `LinqToDB` suffix. E.g. `ToListAsyncLinqToDB()`, `SumAsyncLinqToDB()`, ect.
83+
You can use all `LINQ To DB` extension functions in your EF linq queries. Just ensure you have called `ToLinqToDB()` function before materializing objects.
8784

8885
```cs
8986
using (var ctx = CreateAdventureWorksContext())
@@ -112,8 +109,8 @@ using (var ctx = CreateAdventureWorksContext())
112109
// ensure we have replaced EF context
113110
var items1 = neededRecords.ToLinqToDB().ToArray();
114111

115-
// we have to call our method to avoid naming collisions
116-
var items2 = await neededRecords.ToArrayAsyncLinqToDB();
112+
// async version
113+
var items2 = await neededRecords.ToLinqToDB().ToArrayAsync();
117114

118115
// and simple bonus - how to generate SQL
119116
var sql = neededRecords.ToLinqToDB().ToString();

0 commit comments

Comments
 (0)