Strange issue with CREATE OPERATOR CLASS
От | Josh Berkus |
---|---|
Тема | Strange issue with CREATE OPERATOR CLASS |
Дата | |
Msg-id | 49935924.9050509@agliodbs.com обсуждение исходный текст |
Ответы |
Re: Strange issue with CREATE OPERATOR CLASS
|
Список | pgsql-hackers |
All, I've been working on some scripts (for pgfoundry) which help in "cleaning up" databases which have TSearch and other contrib modules installed to schema public. However, I ran into this odd issue: ERROR: btree operators must return boolean STATEMENT: CREATE OPERATOR CLASS contrib.tsquery_ops DEFAULT FOR TYPE tsquery USING btree AS OPERATOR 1 <(tsquery,tsquery), OPERATOR 2 <=(tsquery,tsquery) , OPERATOR 3 =(tsquery,tsquery) , OPERATOR 4 >=(tsquery,tsquery), OPERATOR 5 >(tsquery,tsquery) , FUNCTION 1 tsquery_cmp(tsquery,tsquery); What appears to be happening there is that PG isn't finding the tsearch operators or is selecting the wrong operators. Manually changing the search_path to "contrib, public" instead of "public, contrib" fixes the issue, but it seems odd that create opclass can't find operators unless they're in the "first" schema in the path, when other CREATE statements have no such difficulty. --Josh
В списке pgsql-hackers по дате отправления: