On do, 2010-02-11 at 03:36 -0800, roomy wrote: > Hi... I was wondering if someone could tell me how can I represent > this mysql statement in django ..... "order by first_name='Yash', > first_name"
http://docs.djangoproject.com/en/dev/ref/models/querysets/#extra-select-none-where-none-params-none-tables-none-order-by-none-select-params-none .extra(select = {'is_yash': "name = 'Yash'}, order_by = ['-is_yash', 'name']) -- Dennis K. The universe tends towards maximum irony. Don't push it. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.