docs: def cursor(self, offset=0, limit=None, order_by=None, as_dict=False):
          """
          See expression.fetch() for input description.
          :return: query cursor
          """
          if offset and limit is None:
              raise DataJointError('limit is required when offset is set')
          sql = self.make_sql()
          if order_by is not None:
              sql += ' ORDER BY ' + ', '.join(order_by)
          if limit is not None:
              sql += ' LIMIT %d' % limit + (' OFFSET %d' % offset if offset else "")
          logger.debug(sql)
          return self.connection.query(sql, as_dict=as_dict)