![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| ||||
| ||||
|
|
I have a table containing polygon and I try a distance operator which fails. (select * from mytable order by point(10,10) <-> mycol) Postgres responds that the operator <-> between a point and a polygon is unknown. I look in the pg_operator.h (in src/include/catalog) where I think all builtin operators are defined and found these definitions |
|
and there is none between a point and a polygon. (600 604) (furthermore the 628 type is defined in ptypes.h as not implemented. I did the following test, I patch the line DATA(insert OID = 613 ( "<->" PGNSP PGUID b f 600 628 701 0 0 0 0 0 0 dist_pl - - )); replacing 628 by 604 , compiling and reinstalling everything including the database |
|
and It works (I didnt verify the result) |
|
So I am wondering , if I miss something, do I have to convert my point in a degenerated circle or polygon) or do you forget one definition ? |
#2
| |||
| |||
|
|
I patch the line DATA(insert OID = 613 ( "<->" PGNSP PGUID b f 600 628 701 0 0 0 0 0 0 dist_pl - - )); replacing 628 by 604 , compiling and reinstalling everything including the database and It works (I didnt verify the result) |
![]() |
| Thread Tools | |
| Display Modes | |
| |