Concurrently invoke queries with different parameters

It seems like it is currently not possible to invoke queries (such as a REST API resource query) concurrently with different parameters, which would be needed when updating multiple rows from a table at once, for example.

The problem with await Promise.all is that it doesn’t actually seem to wait for all of the Promises to finish before declaring the operation to be successful, so refreshing the data afterwards is not possible with either a success event handler or manually adding another query invocation at the end.

Hi @Bendeguz_Acs! Welcome to the community and thanks for your post!

Concurrently invoking queries, and running onSuccess after all are finished running should be possible.

Can you try returning your Promise? Instead of just await Promise.all() and triggering your queries within it, can you try return await Promise.all()? The returned object should resolve when the inner queries have resolved, and it may ensure the success event handler runs when expected.

Let me know if that works!

Hi @diyaayaq , thank you for the reply! It does seem to work that way, is there some documentation that we can refer to about this?