Open ercpe opened 2 months ago
I've created a patch in https://github.com/etianen/django-watson/pull/309.
The Cast
call will use a TextField
as the output, although CharField
(to cast into a varchar
) ought to be enough.
I've left do_string_cast
in place. It's unused now, but someone may rely on it being present in the backend implementation.
It would be great to have this fix merged and released since it's blocking our search. Thanks!
https://github.com/etianen/django-watson/blob/master/watson/search.py#L568 creates a unqualified Cast for the primary key column, which fails if the QuerySet has JOINs (e.g. because it's already filtered):
The Cast should use
U0.id
as the column selector.