Is it possible to do an annotate count on technically 2 different tables, but same FK?
Example:
queryset = ModelName.objects
.annotate(mileage_emp_count=Count('mileageclaim__user',distinct=True))
.annotate(general_emp_count=Count('expenseclaim__user', distinct=True))
For instance using this, is User A has a mileage and an expense claim, they will appear in both queries. So I will have result of 2 if i add them together.
What i need to do, is get a total of 1 unique user instead.
Is it possible without a lot of extra checks?