Guest User

Untitled

a guest
Dec 17th, 2018
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.12 KB | None | 0 0
  1. sq = OrderedModel.objects.annotate(
  2. latest=Window(
  3. expression=Max("order"),
  4. partition_by=["type"]
  5. )
  6. )
Add Comment
Please, Sign In to add comment