Skip to content

V9.6.0

Choose a tag to compare

@jeremydmiller jeremydmiller released this 06 Jul 12:51
· 526 commits to master since this release
f5eae5a

What's Changed

Dialect-neutral command-builder parameter API (#324)

Adds a DbParameter[]-returning AppendWithDbParameters to the non-generic ICommandBuilder surface in both Weasel.Postgresql and Weasel.SqlServer:

DbParameter[] AppendWithDbParameters(string text);
DbParameter[] AppendWithDbParameters(string text, char placeholder);

This lets a database-agnostic consumer fill parameter slots as DbParameter — setting the provider type through its own dialect seam — without referencing NpgsqlParameter or SqlParameter. Each provider upcasts its existing AppendWithParameters result via array covariance, and the method is inherited by every CommandBuilder (Postgres, SQL Server, MySql, Oracle, Sqlite) plus the Postgres and SQL Server BatchBuilders.

This unblocks Marten's closed-shape operation layer becoming fully dialect-neutral (JasperFx/marten#4821 / #4828).

Full Changelog: V9.3.0...V9.6.0