[Sqlalchemy-tickets] Issue #4013: [idea] support __len__ on AppenderQuery to unify usage with non l
Brought to you by:
zzzeek
From: dwt <iss...@bi...> - 2017-06-20 12:40:17
|
New issue 4013: [idea] support __len__ on AppenderQuery to unify usage with non lazy=dynamic loaded collections https://bitbucket.org/zzzeek/sqlalchemy/issues/4013/idea-support-__len__-on-appenderquery-to dwt: Hi there, during a refactoring from lazy=False to lazy=dynamic on some of our relationships, it would have made our life quite a bit easier if the attribute wouldn't have just supported iteration and ranged queries, but also __len__ (to emit a count() query). Is that something you would consider? It shouldn't be too hard to implement. Our use case is, that we have some template mixins, that are quite generic and would like to consume both lazy=dynamic as well as regular relations. |