Re: operator @@ is not supported by path; doc says otherwise

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: operator @@ is not supported by path; doc says otherwise
Дата
Msg-id 3351974.1638816557@sss.pgh.pa.us
обсуждение исходный текст
Ответ на operator @@ is not supported by path; doc says otherwise  (Anton Voloshin <a.voloshin@postgrespro.ru>)
Список pgsql-docs
Anton Voloshin <a.voloshin@postgrespro.ru> writes:
> The documentation for 13 and 14 says in "Geometric Functions and
> Operators" https://www.postgresql.org/docs/14/functions-geometry.html:
>>> @@ geometric_type → point
>>> Computes the center point. Available for box, lseg, path, polygon, circle.
>>> @@ box '(2,2),(0,0)' → (1,1)

> However, apparently, this operator does not work for path:
>>> postgres=# SELECT @@ path '[(0,0),(0,1)]';
>>> ERROR:  function "path_center" not implemented

The fact that this operator is documented is probably my fault
--- when I went through the operator tables not long ago,
I made sure there was an entry for every operator listed in
the system catalogs.  It didn't enter my mind that some of
them might be pointing at useless stubs :-(.

Looking through geo_ops.c, I see that not only path_center
but also dist_lb, dist_bl, close_sl, close_lb, poly_distance
error out with "not implemented".

Given that that code has sat there for more than 20 years
with nobody coming to finish the job, I think we should
just rip those functions and catalog entries out altogether.
It's misleading and probably a small waste of cycles to
have useless entries in pg_proc and pg_operator.

            regards, tom lane



В списке pgsql-docs по дате отправления:

Предыдущее
От: Anton Voloshin
Дата:
Сообщение: operator @@ is not supported by path; doc says otherwise
Следующее
От: PG Doc comments form
Дата:
Сообщение: set time zone