1. Jesper Noehr
  2. django-piston
  3. Issues
Issue #139 new

The emitter should support chained querysets

created an issue

The fix is pretty simple assuming that the user chained a queryset:

in piston/emitters.py instead of: {{{


if isinstance(thing, QuerySet): }}}

use: {{{


import itertools if isinstance(thing, (QuerySet, itertools.chain)): }}}

Chained QuerySets are useful when you need to join two or more QS and you don't have to use UNION in raw SQL.

Comments (0)

  1. Log in to comment