0

In RethinkDB, is it possible to filter and group in a single query using indexes for efficiency in both operations? For instance:

r
    .db('db')
    .table('table')
    .getAll('123', {index: 'serverId'})
    .group({index: 'userId'})
    .ungroup()

When I try this, it throws an error. I read in a few places what seems to suggest that RethinkDB is not capable of using multiple indexes in this way. Is this true or am I doing something wrong?

Chris Talman
  • 1,059
  • 2
  • 14
  • 24

1 Answers1

0

You can use secondary index only one time in a query.

Puneet Uppal
  • 195
  • 10