DapperLib / DapperLib/DapperAOT
Converting Query<MyObject> to QueryFirstOrDefault<MyObject> breaks query
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 472
- Forks
- 43
- Avg merge
- 1d 4h
- Merged PRs (30d)
- 18
Description
At the suggestion of the Dapper.AOT system I converted SELECT query type calls from Query("SELECT * FROM my_object_table WHERE id=@foo") style calls to the QueryFirstOrDefault() syntax
What happens is for the same SQL, the query returns an empty object so it breaks things.
**Where are you seeing this?
Dapper 2.1.35
Dapper.AOT 2.0.78
MariaDB 10.11.6
To Reproduce
Try a query with Dapper before and after converting to the QueryFirstOrDefault() style
Expected behavior
I expected my queries to work as before
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No files, tests, or entry points are named. Start by creating the minimal comparison described in the issue using Dapper 2.1.35, Dapper.AOT 2.0.78, and MariaDB 10.11.6, then compare Query with QueryFirstOrDefault for the same SQL. Done means the converted query returns the expected populated object rather than an empty one.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, mariadb
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100