i am using postgresql version : "PostgreSQL 9.3.1 on x86_64-unknown-linux-gnu, compiled by gcc (GCC) 4.6.3 20120306 (Red Hat 4.6.3-2), 64-bit"
i have created 2 tables A and B with point and polygon as a data type. now i want to know whether point is inside the polygon or not. for this i am trying to use ST_Intersect(A.point_LatLong , B.polygon_abc); my query is :
SELECT A.id
FROM A, B
WHERE A.name = 'callifornia'
AND ST_Intersect(A.point_LatLong , B.polygon_abc);
here point_latLong
and polygon_abc
are column name having datatype point and polygon in table A and B.
but this query gives an error :
ERROR: function st_intersect(point, polygon) does not exist
LINE 3: WHERE city.city_name = 'callifornia' AND ST_intersect(city.c...
HINT: No function matches the given name and argument types. You might need to add
explicit type casts.
How can I solve this problem? I even not be able to use any other spatial method in postgresql like st_contains() etc let me know if you have any solution.