We have an internal reporting feature we are migrating to Retool, however, we can't really figure out how to populate MongoDB queries or run dynamic queries where inputs are values being looped over.
The fact that it is completely async might make it all-the-more difficult to migrate in our assumption but we'd like a try anyway. We just want to replicate the TypeScript code for now to offload the spikes our reporting tool causes to our app directly to the MongoDB server.
You can use .trigger() in a JS query to trigger Mongo queries and you can pass data from the JS query to dynamically populate your mongodb query. It sounds like that would be helpful here?
For example, you can loop over recordUpdates and trigger a separate mongo query for each record: