Possibly detect adapter support for recursive queries
- Dominant language
- Ruby
- Stars
- 90
- Forks
- 9
- PR merge metrics
- No merged PRs in 30d
Description
Would it be feasible to attempt to detect support for recursive queries from the database adapter, an revert to a naive approach if it isn't available? This way it would be possible to use edge with SQLite and MySQL without needing any changes in client code.
I have two ideas on how this could be implemented:
1) Run a test query the first time a recursive query needs to be performed, and store whether it succeeded or not in a per-adapter module-wide variable. Then use that to decide what approach to use for subsequent queries.
2) Attempt to catch syntax errors on recursive query execution, fallback to the naive approach, and also cache the failure as above.
If this is desirable and not considered to hacky I can do it and send a PR.
Contributor guide
No contributing guide indexed for this repository
Research direction
No files or tests are named. Begin by locating recursive-query execution and database-adapter capability handling, then evaluate the proposed detection, caching, and fallback behavior; done means supported adapters can use recursive queries while unsupported adapters continue with the naive approach.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- mysql, ruby, sql, sqlite
- Domain
- backend, databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100