Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add overload that allows a custom parameter placeholder. #3622

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

elexisvenator
Copy link
Contributor

@elexisvenator elexisvenator commented Jan 10, 2025

The char placeholder param is always before the string sql param. This is to ensure that the overload is backwards compatible.,

Updated all methods that accept parameters except for:

  • Sync methods that are marked obsolete
  • MatchesJsonPath - This should probably be marked as obsolete as the placeholder overload does the same thing but better.

Todo:

  • Tests.
  • Documentation.
    Will circle back to these after the weekend.

The `char placeholder` param is always before the `string sql` param. This is to ensure that the overload is backwards compatible.,

Updated all methods that accept parameters except for:
- Sync methods that are marked obsolete
- `MatchesJsonPath` - This should probably be marked as obsolete as the placeholder overload does the same thing but better.

Todo:
- Tests.
@@ -62,6 +114,7 @@ public interface IAdvancedSql
/// <param name="sql"></param>
/// <param name="parameters"></param>
/// <returns></returns>
[Obsolete(QuerySession.SynchronousRemoval)]
IReadOnlyList<T> Query<T>(string sql, params object[] parameters);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of spots where the obsolete warning for synchronous db methods was missing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant