DB = sqlite I don't now if this is a bug or an issue with my mapper config, but the count() method does not work correctly through relationships. Given this mapper:
mapper(Branch, branches, properties={ 'reports':dynamic_loader(Report, backref='branch') }) b = sess.query(Branch).first() print len(b.reports.all()) # returns the correct number or reports for this branch. print b.reports.count() # ignores the relationship returns the total number of reports in the database. Thanks, - Justin Driscoll --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---