You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+110-6Lines changed: 110 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -19,9 +19,110 @@ The `AsQueryableValues` extension method is intended for queries that are depend
19
19
20
20
It provides a solution to the following long standing [EF Core issue](https://github.com/dotnet/efcore/issues/13617) and enables other currently unsupported scenarios; like the ability to efficiently create joins with in-memory data.
21
21
22
-
## Getting Started
22
+
## Benchmarks
23
+
The following [benchmarks] consist of EF Core queries that have a dependency on a random sequence of [Int32] and [Guid] values via the `Contains` LINQ method. It shows the performance differences between not using and using QueryableValues.
QueryableValues is distributed as a [NuGet Package]. The major version number of this library is aligned with the version of [Entity Framework Core] by which it's supported (e.g. If you are using EF Core 5, then you must use version 5 of QueryableValues).
26
127
27
128
Please choose the appropriate command below to install it using the NuGet Package Manager Console window in Visual Studio:
Look for the place in your code where you are setting up your [DbContext] and calling the [UseSqlServer] extension method, then use a lambda expression to access the `SqlServerDbContextOptionsBuilder` provided by it. It is on this builder that you must call the `UseQueryableValues` extension method as shown in the following simplified examples:
37
138
38
139
When using the `OnConfiguring` method inside your [DbContext]:
@@ -74,15 +175,15 @@ public class Startup
74
175
}
75
176
```
76
177
77
-
###How Do You Use It?
178
+
## How Do You Use It?
78
179
The `AsQueryableValues` extension method is provided by the `BlazarTech.QueryableValues` namespace; therefore, you must add the following `using` directive to your source code file for it to appear as a method of your [DbContext] instance:
79
180
```
80
181
using BlazarTech.QueryableValues;
81
182
```
82
183
83
184
Below are a few examples composing a query using the values provided by an [IEnumerable\<T\>].
84
185
85
-
####Simple Type Examples
186
+
### Simple Type Examples
86
187
Using the [Contains][ContainsQueryable] LINQ method:
87
188
88
189
```c#
@@ -141,7 +242,7 @@ var myQuery2 =
141
242
i.PropA
142
243
};
143
244
```
144
-
####Complex Type Example
245
+
### Complex Type Example
145
246
```c#
146
247
// Performance Tip:
147
248
// If your IEnumerable<T> item type (T) has many properties, project only
0 commit comments