Dave Lowe schrieb: > Here's the Django side: > > results = Product.objects.extra( > select={ > 'rank': "rank_cd(textsearchable, query, 32)", > }, > tables=["to_tsquery(%s) as query"], > where=["textsearchable @@ query"], > params=[terms] > ).order_by('-rank') > > I guess "to_tsquery(%s) as query" is a column and not a table.
According to http://www.djangoproject.com/documentation/db-api/ you need select_params select={ 'rank': "rank_cd(textsearchable, to_tsquery(%s), 32)", }, Thomas -- Thomas Guettler, http://www.thomas-guettler.de/ E-Mail: guettli (*) thomas-guettler + de --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com 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 -~----------~----~----~----~------~----~------~--~---