'Yield only ``count`` rows at a time.
WARNING: use this method with caution; if the same instance is present
in more than one batch of rows, end-user changes to attributes will be
overwritten.
In particular, it\'s usually impossible to use this setting with
eagerly loaded collections (i.e. any lazy=\'joined\' or \'subquery\')
since those collections will be cleared for a new load when
encountered in a subsequent result batch.   In the case of \'subquery\'
loading, the full result for all rows is fetched which generally
defeats the purpose of :meth:`~sqlalchemy.orm.query.Query.yield_per`.
Also note that while :meth:`~sqlalchemy.orm.query.Query.yield_per`
will set the ``stream_results`` execution option to True, currently
this is only understood by :mod:`~sqlalchemy.dialects.postgresql.psycopg2` dialect
which will stream results using server side cursors instead of pre-buffer
all rows for this query. Other DBAPIs pre-buffer all rows before
making them available.'

@_generative()
def yield_per(self, count):

    self._yield_per = count
    self._execution_options = self._execution_options.union({'stream_results': True})
