Can you please provide more information on how to reproduce the error? At first sight the outer braces look strange to me. Did you enter the WKT by hand?
Sorry the outer braces is my mistake. The true message is here: Unable to parse WKT: POINT(1.52109 42.50779)
I didn't enter the WKT, I used OpenLayers Map to add/edit point.
There is no special need to reproduce the error. I install the Cartaro distribution with demo data (Capitals). After that, I tried to add a Capital and when I saved it I got the error message. The same error also appears when I'm editing a Capital.
Facing same issue here.
Unable to parse WKT: POINT(54.36667 24.46667)
Drupal 7.22
Install profile Cartaro (cartaro-7.x-1.0)
Database system PostgreSQL
Database system version 9.2.4
Database updates Up to date
Drupal core update status Up to date
PHP 5.3.15 (Mountain Lion)
PostGIS 2.0
Web server Apache/2.2.22 (Unix) DAV/2 PHP/5.3.15 with Suhosin-Patch mod_ssl/2.2.22 OpenSSL/0.9.8x
My bad, had a duplicated POSTGIS. I realized after debugging and seeing the exception:
Unable to parse WKT: POINT(-5273543.4561062 -1603954.5996489) exception 'PDOException' with message 'SQLSTATE[42725]: Ambiguous function: 7 ERROR: function st_geometrytype(unknown) is not unique
Dropping the extension (DROP EXTENSION postgis_topology;) solved the problem.
Digging through the code in postgis.geometry.inc, it looks like it is trying to do SELECT ST_GeometryType('POLYGON(...)'); instead of SELECT ST_GeometryType(ST_GeometryFromText('POLYGON(...)')); which might be the problem, but I'm not particularly familiar with php or postgis so I could be reading it incorrectly.
I experienced the same problem as irishsetter. Perhaps it should be mentioned, that PostGIS module isn't compatible with postgis_topology extension. Or am I missing something?
Comments
Comment #1
friedjoff commentedCan you please provide more information on how to reproduce the error? At first sight the outer braces look strange to me. Did you enter the WKT by hand?
Comment #2
kokkytos commentedSorry the outer braces is my mistake. The true message is here:
Unable to parse WKT: POINT(1.52109 42.50779)
I didn't enter the WKT, I used OpenLayers Map to add/edit point.
Comment #3
kokkytos commentedThere is no special need to reproduce the error. I install the Cartaro distribution with demo data (Capitals). After that, I tried to add a Capital and when I saved it I got the error message. The same error also appears when I'm editing a Capital.
Comment #4
friedjoff commentedCan you tell me which version of PHP, PostgreSQL and PostGIS you're using (Administration > Reports > Status reports)?
Comment #5
kokkytos commentedOK
PHP 5.4.4
PostGIS 2.0
PostgreSQL 9.2.1
The problem was with 7.x-1.x-dev
I installed 7.x-1.0-beta1 and there is no problem. Maybe there was a misconfiguration
Thank you for you time!
Comment #6
friedjoff commentedComment #8
irishsetter commentedFacing same issue here.
Unable to parse WKT: POINT(54.36667 24.46667)
Drupal 7.22
Install profile Cartaro (cartaro-7.x-1.0)
Database system PostgreSQL
Database system version 9.2.4
Database updates Up to date
Drupal core update status Up to date
PHP 5.3.15 (Mountain Lion)
PostGIS 2.0
Web server Apache/2.2.22 (Unix) DAV/2 PHP/5.3.15 with Suhosin-Patch mod_ssl/2.2.22 OpenSSL/0.9.8x
Comment #9
irishsetter commentedMy bad, had a duplicated POSTGIS. I realized after debugging and seeing the exception:
Unable to parse WKT: POINT(-5273543.4561062 -1603954.5996489) exception 'PDOException' with message 'SQLSTATE[42725]: Ambiguous function: 7 ERROR: function st_geometrytype(unknown) is not unique
Dropping the extension (DROP EXTENSION postgis_topology;) solved the problem.
Comment #10
irishsetter commentedComment #11
aquavitae commentedI'm getting this too:
Unable to parse WKT: POLYGON((2323165.9017765 -3715665.1528316,2325153.2645117 -3715818.0268882,2323471.6498896 -3717652.5155667,2323165.9017765 -3715665.1528316))
If I execute the query directly in psql it works though:
Digging through the code in postgis.geometry.inc, it looks like it is trying to do
SELECT ST_GeometryType('POLYGON(...)');instead ofSELECT ST_GeometryType(ST_GeometryFromText('POLYGON(...)'));which might be the problem, but I'm not particularly familiar with php or postgis so I could be reading it incorrectly.Comment #12
milos.kroulik commentedI experienced the same problem as irishsetter. Perhaps it should be mentioned, that PostGIS module isn't compatible with postgis_topology extension. Or am I missing something?