RethinkDB JOIN Example

You can do a simple inner join in RethinkDB with the “eqJoin” method. This takes an ID, and a second table (in this case, I’ve done a self-join):

r.db('test')
 .table('users')
 .eqJoin(
     'id',
     r.table('users')
   )