[SOLVED] Pipeline queries not working

Hi,
I am currently working with pipeline queries and have 2 variables containing 2 different pipeline constants. However, the server does not seem to execute them. If I take any of the two out, the other one works. Both queries are perfectly working in the JS console and have been accurately tested.
Does this have anything to do with a limitation regarding Moralis free plan?
The two queries are quite complex, but I am testing them on very small sets of data.

it is not related to the plan, you may have to create two separate pipelines

Yes I have in fact created two different pipeline variables. The error it’s giving me is the following:

Object {
  "code": 102,
  "error": "Invalid parameter for query: group. Please use objectId instead of _id",
}

I have already tried restarting the server by the way. Although it may seem like an error related to my code, it just disappears when removing one of the two pipelines.

The part of the code related to the error is in fact correct as shown below:

{
     group:{
       objectId: "$brand.name",
       count: { "$sum": 1 }
     }
},

The error is saying I should use “objectId” instead of “_id” but I’m already using that.

what is the version that works?

After restarting my machine, re-uploading the cloud code and restarting manually the moralis server once again it now appears to be working. Strange fact…

1 Like