DapperLib / DapperLib/Dapper

Access both GetRowParser and GridReader.Read<TFirst,TSecond,TReturn> on the same query

Open
#624 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
18.4k
Forks
3.7k
Avg merge
5h 8m
Merged PRs (30d)
1

Description

I have a stored procedure that contains multiple select statements. One of the select is for a discriminated union, and another contains multiple objects in a single row. It seems that I can use datareader.GetRowParser for the former and GridReader.Read<TFirst,TSecond,TReturn> for the latter. But is there a way I can do both in one query? I was hoping GridReader has a public access to its datareader, so I can call RowParser(GridReader.DataReader), but no such luck. Is there an alternative way to achieve this?
Thank you.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source files or tests are named. Start by tracing GridReader.Read<TFirst,TSecond,TReturn> and GetRowParser around their data-reader access, then inspect existing tests for multiple result sets and row parsers. Done should be a clearly scoped, supported way to combine both mappings, with coverage for the stored-procedure scenario.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, sql
Domain
backend-api-design, databases
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.