Questions tagged as 'django-annotate'

1
answer

Grouping values in Django

I'm having a bit of trouble putting together some information, from separate models. For example: I have 3 models, one call Category , another call Group and another call Tools . These tables will get the name and slug o...
asked by 16.01.2018 / 19:26
0
answers

Using extra field in Django Annotate

I'm trying to add a column named today in a Model with .extra() , to work on an annotate . I'm not finding. He is not finding the field. duration = ExpressionWrapper(F('today') - F('pub_date'), output_field=fields.DurationField()...
asked by 14.09.2017 / 17:24