Query filter based on reference collection value?

Is it possible to define a query based on the reference collection? I’m using the below query which works against MemberJourneyDev and it references MemberDataDev (via ‘email’).

querystring = wixData.query(“MemberJourneyDev”).include(“email”).ne(“inactive”, true)

return querystring
    .find()
    .then((results) => {
        return results.items
    })
    .catch((err) => {
        let errorMsg = err;
        console.log("Returned nothing")
    });

console.log(X)

}

Is it possible to add something like

.eq (“email.firstName”, “John”)

To my query so it filters on values in the reference collection (MemberDataDev)?

This isn’t currently possible. You’d need to retrieve the data in the query and then filter it after.

If you’d like to see such a feature you can request it here: Product Roadmap