denodrivers / denodrivers/mysql
Request: A one query method to cover all of them
- Dominant language
- TypeScript
- Stars
- 264
- Forks
- 64
- PR merge metrics
- No merged PRs in 30d
Description
Hi! I really appreciate the work you have put into this library!
When automating queries it's not always possible to know if a request will be a query or an execution. Would it be possible to have one method exposed which handles any type of query? Currently, if I use `execute`, it will throw an error if the response is empty (e.g. from a select statement), and if I use `query` it will time out if I use an insert/delete/update statement. Maybe changing execute to not throw on empty but rather return undefined or null would be an option?
Thanks!
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reading the existing `query` and `execute` entry points and how they handle empty responses, SELECT statements, and INSERT/DELETE/UPDATE statements. Define the unified method's return and error behavior for both result-producing and empty operations, then verify that neither operation times out nor raises an error unexpectedly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- mysql, typescript
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100