Optimise sub queries
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 7
- Forks
- 7
- Avg merge
- 9h 4m
- Merged PRs (30d)
- 22
Description
mongo-knex generates for some cases multiple sub queries in the where clause e.g. for
$and: [{'tags.slug': 'en'}, {'tags.slug': 'de'}]
But there are some cases where we currently generate multiple sub queries, where we don't have to.
This issue should simply collect use cases over time to optimise the performance of the attached queries. I will leave a comment with a use case i discovered in a bit.
Just leave a comment if you discover or want to discuss a case 👍
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 documenting a concrete mongo-knex case that generates redundant subqueries, then compare the generated queries and use the collected cases to define when the optimization is complete.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, mongodb
- Domain
- database
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100