

def get_count_select(self):
    s = self.get_bare_select(columns=[self.table.c.pk])
    count_select = select([func.count()]).select_from(s.alias())
    return count_select

dataset/ETHPy150Open adewes/blitzdb/blitzdb/backends/sql/queryset.py QuerySet.get_count_select/original