MongoDB Query has no additionalScope?

In trying to reference the documentation around JS triggers, it doesn't appear that a MongoDB Query has any place to setup an additionalScope. Does this work some other way?

What I have is a JS Query like so
image

But unlike in the example, I don't see anywhere that lets the Mongo query accept the additionalScope of "reporter_id", it just always resolves as not defined... :frowning:

image

Half-solving my own issue, but it really looks like what I should be doing here is making use of an aggregation in my original Mongo query to put together all the information I want, rather than rely on triggers.

Hi @Cryptite,

Were you able to get it working using an aggregation?

I was, thanks for the followup!

1 Like