Thanks Vincent and Elliot.

On Tue, Jul 3, 2012 at 11:41 AM, cubells <[email protected]> wrote:

> It means "in descending order"
>
> , Vicent Cubells.
>
>
> ----- Reply message -----
> De: "Smaran Harihar" <[email protected]>
> Para: <[email protected]>
> Asunto: Tutorial three '-pub_date'
> Fecha: mar., jul. 3, 2012 20:33
>
>
> Hey Djangoers,
>
> I am on the tutorial 
> 3<https://docs..djangoproject.com/en/dev/intro/tutorial03/#write-views-that-actually-do-something>,
> and found this code where we are modifying the view index()
>
> def index(request):
>     latest_poll_list = Poll.objects.all().order_by('-pub_date')[:5]
>     output = ', '.join([p.question for p in latest_poll_list])
>     return HttpResponse(output)
>
> What I did not understand, was why did we state,
>
> order_by('-pub_date'), what does that *'-'* mean before 'pub_date' ?
>
> --
> Thanks & Regards
> Smaran Harihar
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>



-- 
Thanks & Regards
Smaran Harihar

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to