Queryset return the first term and the last one, are used as follows:
p = Blog.objects.order_by('title').first()
Equivalent to:
try: p = Blog.objects.order_by('title')[0] except IndexError: p = None
Queryset return the first term and the last one, are used as follows:
p = Blog.objects.order_by('title').first()
Equivalent to:
try: p = Blog.objects.order_by('title')[0] except IndexError: p = None