[Answered ]-How to specify the SearchVector content manually in Django for Postgres?

1👍

The arguments to SearchVector can be any Expression or the name of a field. Multiple arguments will be concatenated together using a space so that the search document includes them all.

SearchVector(Value('some text'))

Thanks to Swen for the answer.

0👍

I think you just use the search look up.

Taken from – https://docs.djangoproject.com/en/3.2/ref/contrib/postgres/search/#the-search-lookup

Entry.objects.filter(body_text__search='Cheese')

Leave a comment