long running queries
hi all, any idea how can i fix "This query or mutation function ran multiple paginated queries. Convex only supports a single paginated query in each function."?
3 Replies
Thanks for posting in <#1088161997662724167>.
Reminder: If you have a Convex Pro account, use the Convex Dashboard to file support tickets.
- Provide context: What are you trying to achieve, what is the end-user interaction, what are you seeing? (full error message, command output, etc.)
- Use search.convex.dev to search Docs, Stack, and Discord all at once.
- Additionally, you can post your questions in the Convex Community's <#1228095053885476985> channel to receive a response from AI.
- Avoid tagging staff unless specifically instructed.
Thank you!
Yes. you can't paginate() more than once per function. I've faced this problem also. Can you explain what you're trying to achieve, maybe there can be a better way around your problem; the code looks like it may cause problems later...
Convex helpers provides a paginate() replacement that doesn't have this limitation: https://github.com/get-convex/convex-helpers/tree/main/packages/convex-helpers#paginator-manual-pagination-with-familiar-syntax
GitHub
convex-helpers/packages/convex-helpers at main · get-convex/convex...
A collection of useful code to complement the official packages. - get-convex/convex-helpers