Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Source/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
<!-- Release candidate line: delete this element (or pass -p:VersionSuffix=) to build the stable 11.0.0 packages. -->
<VersionSuffix Condition="'$(Configuration)' != 'Debug'">rc.4</VersionSuffix>

<!-- A package built on a developer machine must not carry that machine's folder names. In a Release build the SDK maps the repository root to a neutral prefix
in every path it embeds: the source files, the debug-symbol path inside each dll, and the Source Link mapping inside the symbols. -->
<DeterministicSourcePaths Condition="'$(Configuration)' == 'Release'">true</DeterministicSourcePaths>

<!-- net11.0 is the primary/modern target: each major version of ODX targets the matching .NET.
net10.0 (LTS) stays alongside it. netstandard2.0/2.1 are retained as shimmed
legacy paths (via #if switching + BCL compat packages). net472 lives only on the
Expand Down
1 change: 1 addition & 0 deletions docsite/articles/whats-new-11.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Version 11 is a performance release and a tidy-up release. Result mapping is rew

## Changes since rc.4

- A package built in a Release build no longer carries the build machine's folder names: the SDK's `DeterministicSourcePaths` maps the repository folder to a neutral prefix in the dll, the debug symbols and the Source Link mapping.
- Version 11 targets .NET 11: every package adds `net11.0` next to `net10.0` (LTS), `netstandard2.0` and `netstandard2.1` (`MSSqlClient`: `net472`, `net10.0` and `net11.0`). Each major version of the library targets the matching .NET. Building the repository needs the .NET 11 SDK (`global.json`).
- `.SingleResult()` can be written before `Map`, so a query reads as behavior first, then shape: `command.SingleResult().Map<Post>().ToListAsync(cancellationToken)`. It works on an expressive command (`IExecuteReader`) and on a raw `IDbCommand` or `DbCommand`, with the same `Map` overloads as before, and it is the same as `command.Map<Post>().SingleResult()`, which still works. There is none on `IDataReader` or `DataTable`: their views never read through, so there is nothing to opt out of. Nothing changes by default: without it a `Map` terminal still reads through the later result sets.
- **`ExecuteScalar<T>()` and `ExecuteScalarAsync<T>()` convert the way `Map<T>()` does.** They cast the provider's value exactly, so a `bigint` read as `int`, or a `numeric` read as `long`, threw `InvalidCastException`, which a port from Dapper met only on a real database. Now a value that is already a `T` is returned as it is, an integer converts to another integer type with a range check, and any other value is converted by the same code `Map<T>()` uses. `NULL` and no row still give `default(T)`. A value that cannot be converted, or does not fit, throws `ValueMappingException` with the conversion's error inside. **Behavior change:** a call that threw `InvalidCastException` now converts, or throws that exception. `ExecuteReturn<T>()` and `ExecuteReturnAsync<T>()` convert the same way. The overloads that take a `Func<object?, T>` are unchanged.
Expand Down
Loading