Is there a sum() or count() function in queries?

I noticed there are several “functions” for distance matching in a where clause.

Are there any functions you can apply to props returned from a query, e.g. sum(<field>), count(<field>), etc.?

Not yet, but this is in the scope for the current iteration.

Regards,
Mark

How far off is that? A sum() function is critical for me to be able to deliver my game. Otherwise I will have to do a huge amount of data queries and movement, and processing in a script.

We do not set strict dates, it will be delivered when it is ready. Could take a month, maybe longer.

Consider using server-side business logic to re-calculate sum as data is added/updated.

Regards,
Mark

I am using server side logic, however the script needs to pull many records per user per interval (e.g. every 1 minute) to sum a value and write back. If I could sum() in a “find” query, I can do it in one step.

And that’s exactly why we’re adding that capability… so you can do it easier. ))

If that is a month or so away, that is fantastic!!! :slight_smile:

Any update on this? Is there a way to do that now? I don’t find anything in the docs.

Hi Ludwig,

It is in the schedule for the 3.2 release. I do not have a time estimate on it yet.

Regards,
Mark