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
You can also obtain it a local tool when you restore the dependencies of a project that declares it as a tooling dependency using a [tool manifest file](/dotnet/core/tools/global-tools#install-a-local-tool).
181
185
186
+
## Low impact
187
+
182
188
<aname="fromsql"></a>
183
189
184
190
### FromSql, ExecuteSql, and ExecuteSqlAsync have been renamed
HasGeometricDimension was used to enable additional dimensions (Z and M) on geometry columns. However, it only ever affected database creation. It was unnecessary to specify it to query values with additional dimensions. It also didn't work correctly when inserting or updating values with additional dimensions ([see #14257](https://github.com/aspnet/EntityFrameworkCore/issues/14257)).
40
-
41
-
#### New behavior
42
-
43
-
To enable inserting and updating geometry values with additional dimensions (Z and M), the dimension needs to be specified as part of the column type name. This API matches more closely to the underlying behavior of SpatiaLite's AddGeometryColumn function.
44
-
45
-
#### Why
46
-
47
-
Using HasGeometricDimension after specifying the dimension in the column type is unnecessary and redundant, so we removed HasGeometricDimension entirely.
48
-
49
-
#### Mitigations
50
-
51
-
Use `HasColumnType` to specify the dimension:
52
-
53
-
```csharp
54
-
modelBuilder.Entity<GeoEntity>(
55
-
x=>
56
-
{
57
-
// Allow any GEOMETRY value with optional Z and M values
Entity types were mapped to defining queries at the Core level. Anytime the entity type was used in the query root of the entity type was replaced by the defining query for any provider.
82
+
83
+
#### New behavior
84
+
85
+
APIs for defining query are deprecated. New provider-specific APIs were introduced.
86
+
87
+
#### Why
88
+
89
+
While defining queries were implemented as replacement query whenever query root is used in the query, it had a few issues:
90
+
91
+
- If defining query is projecting entity type using `new { ... }` in `Select` method, then identifying that as an entity required additional work and made it inconsistent with how EF Core treats nominal types in the query.
92
+
- For relational providers `FromSql` is still needed to pass the SQL string in LINQ expression form.
93
+
94
+
Initially defining queries were introduced as client-side views to be used with In-Memory provider for keyless entities (similar to database views in relational databases). Such definition makes it easy to test application against in-memory database. Afterwards they became broadly applicable, which was useful but brought inconsistent and hard to understand behavior. So we decided to simplify the concept. We made LINQ based defining query exclusive to In-Memory provider and treat them differently. For more information, [see this issue](https://github.com/dotnet/efcore/issues/20023).
95
+
96
+
#### Mitigations
97
+
98
+
For relational providers, use `ToSqlQuery` method in `OnModelCreating` and pass in a SQL string to use for the entity type.
99
+
For the In-Memory provider, use `ToInMemoryQuery` method in `OnModelCreating` and pass in a LINQ query to use for the entity type.
100
+
101
+
## Low impact
102
+
103
+
<aname="geometric-sqlite"></a>
104
+
105
+
### Removed HasGeometricDimension method from SQLite NTS extension
HasGeometricDimension was used to enable additional dimensions (Z and M) on geometry columns. However, it only ever affected database creation. It was unnecessary to specify it to query values with additional dimensions. It also didn't work correctly when inserting or updating values with additional dimensions ([see #14257](https://github.com/aspnet/EntityFrameworkCore/issues/14257)).
112
+
113
+
#### New behavior
114
+
115
+
To enable inserting and updating geometry values with additional dimensions (Z and M), the dimension needs to be specified as part of the column type name. This API matches more closely to the underlying behavior of SpatiaLite's AddGeometryColumn function.
116
+
117
+
#### Why
118
+
119
+
Using HasGeometricDimension after specifying the dimension in the column type is unnecessary and redundant, so we removed HasGeometricDimension entirely.
120
+
121
+
#### Mitigations
122
+
123
+
Use `HasColumnType` to specify the dimension:
124
+
125
+
```csharp
126
+
modelBuilder.Entity<GeoEntity>(
127
+
x=>
128
+
{
129
+
// Allow any GEOMETRY value with optional Z and M values
Entity types were mapped to defining queries at the Core level. Anytime the entity type was used in the query root of the entity type was replaced by the defining query for any provider.
303
-
304
-
#### New behavior
305
-
306
-
APIs for defining query are deprecated. New provider-specific APIs were introduced.
307
-
308
-
#### Why
309
-
310
-
While defining queries were implemented as replacement query whenever query root is used in the query, it had a few issues:
311
-
312
-
- If defining query is projecting entity type using `new { ... }` in `Select` method, then identifying that as an entity required additional work and made it inconsistent with how EF Core treats nominal types in the query.
313
-
- For relational providers `FromSql` is still needed to pass the SQL string in LINQ expression form.
314
-
315
-
Initially defining queries were introduced as client-side views to be used with In-Memory provider for keyless entities (similar to database views in relational databases). Such definition makes it easy to test application against in-memory database. Afterwards they became broadly applicable, which was useful but brought inconsistent and hard to understand behavior. So we decided to simplify the concept. We made LINQ based defining query exclusive to In-Memory provider and treat them differently. For more information, [see this issue](https://github.com/dotnet/efcore/issues/20023).
316
-
317
-
#### Mitigations
318
-
319
-
For relational providers, use `ToSqlQuery` method in `OnModelCreating` and pass in a SQL string to use for the entity type.
320
-
For the In-Memory provider, use `ToInMemoryQuery` method in `OnModelCreating` and pass in a LINQ query to use for the entity type.
321
-
322
326
<aname="no-client-methods"></a>
323
327
324
328
### Provider-specific EF.Functions methods throw for InMemory provider
@@ -367,13 +371,13 @@ If your project includes migrations generated prior to EF Core version 2.0.0, yo
367
371
368
372
<aname="pluralizer"></a>
369
373
370
-
### A pluarlizer is now included for scaffolding reverse engineered models
374
+
### A pluralizer is now included for scaffolding reverse engineered models
Previously, you had to install a separate pluralizer package in order to pluralize DbSet and collection navigation names and singularize table names when scaffoding a DbContext and entity types by reverse engineering a database schema.
380
+
Previously, you had to install a separate pluralizer package in order to pluralize DbSet and collection navigation names and singularize table names when scaffolding a DbContext and entity types by reverse engineering a database schema.
0 commit comments