Skip to content

Python code snippet – How to get last values or data in django orm?

my_queryset.reverse()[:5]
See also  How to get the current date hour minute month year in Python?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.