Define my own interpolator
Nobody has claimed this yet.
- Dominant language
- Scala
- Stars
- 2.2k
- Forks
- 379
- Avg merge
- 14m
- Merged PRs (30d)
- 8
Description
Hi, I really like Doobie, good work!
But I would like to define my own interpolator. In particular I was considering to:
- Allow variables anywhere in the query, and use
?$for the variables that need to be replaced with?(just reading the last character in the previous fragment), this should allow using variables for table names, if I'm not mistaken - Have a default transactor in the same class where the interpolator is defined to execute the
ConnectionIOinto aFuturewith the results.
I was trying to use all the Doobie goodies for execution of the queries, type conversion, etc. But you are very clever and I can barely understand your code 😅
Is there any way to not use the sql interpolator but use the Doobie API directly? I have probably read the relevant code, but I cannot find a way to use it.
Thank you!
Contributor guide
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
The request centers on Doobie's SQL interpolator and direct Doobie API; start by tracing the interpolator and the API used to execute ConnectionIO. Determine whether custom interpolation, variables in arbitrary query positions, and a default transactor are supported, and document the supported path or the required design decisions.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- scala, sql
- Domain
- database
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100