https://issues.qgis.org/https://issues.qgis.org/favicon.ico2011-12-16T13:10:13ZQGIS Issue TrackingQGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=276542011-12-16T13:10:13ZGiovanni Manghigiovanni.manghi@gmail.com
<ul><li><strong>Target version</strong> set to <i>Version 1.7.4</i></li></ul> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=285892012-01-16T07:19:53ZSai Nerella
<ul><li><strong>Affected QGIS version</strong> set to <i>master</i></li><li><strong>Crashes QGIS or corrupts data</strong> set to <i>No</i></li></ul><p>Any update on this issue? I am using Quantum GIS 1.7.3 to identify features on Postgis 1.5.2 layers. I have the same issue.</p>
<p>1 cursor states lost.<br />SQL: declare qgisf2 binary cursor for select<br />function intersects(geography, geometry) does not exist....<br />LINE 1: ...4336602647 43.8916652467107795)'::box3d,4326) and intersects........<br />HINT: No function matches the given name and argument types. You might need to add explicit type casts.<br />)...</p> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=286322012-01-18T06:46:00ZAlexander Bruy
<ul></ul><p>Confirmed on master with PostGIS 2.0SVN database. Errors are<br /><pre>
1 cursor states lost.
SQL: CLOSE qgisf0
Result: 7 (ERROR: current transaction is aborted, commands ignored until end of transaction block)
Fetching from cursor qgisf0 failed
Database error: ERROR: Operation on mixed SRID geometries
Query: CLOSE qgisf0 returned 7 [ERROR: current transaction is aborted, commands ignored until end of transaction block]
</pre></p> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=286382012-01-18T11:35:57ZSandro Santillistrk@kbt.io
<ul></ul><p>Alexander: are you also using 1.7.3 ? Did you try with 1.7 branch ?</p>
<p>Sai Nerella: your case is a different one. If you still have problem with the 1.7 git branch please file another ticket.</p> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=286392012-01-18T11:37:28ZSandro Santillistrk@kbt.io
<ul></ul><p>I think my issue is about having geometries with mixed SRIDs into the same table. Something for which support seems fixed in master in that rows are also filtered by SRID. Do you confirm jef ?</p> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=286502012-01-19T09:56:26ZAlexander Bruy
<ul></ul><p>Sandro Santilli wrote:</p>
<blockquote>
<p>Alexander: are you also using 1.7.3 ? Did you try with 1.7 branch ?</p>
</blockquote>
<p>No, I'm on master. Now with <a class="changeset" href="https://issues.qgis.org/projects/qgis/repository/revisions/27249d88d1a86e2eb92c72b2d971162c467cf7e0" title="force most core dialogs to remember their state and restore it when opened (adresses #206)">27249d8</a> I can't reproduce this error</p> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=286522012-01-19T13:26:04ZSandro Santillistrk@kbt.io
<ul><li><strong>Target version</strong> changed from <i>Version 1.7.4</i> to <i>Version 2.0.0</i></li><li><strong>Resolution</strong> set to <i>fixed</i></li></ul><p>I'll assume it's fixed then. Could not reproduce with 1.7, if anyone can feel free to reopen or file another one.</p> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=286742012-01-22T22:48:43ZJürgen Fischerjef@norbit.de
<ul><li><strong>Status</strong> changed from <i>Open</i> to <i>Closed</i></li></ul> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=396072013-03-23T04:41:06ZRudi von Staden
<ul><li><strong>Status</strong> changed from <i>Closed</i> to <i>Reopened</i></li></ul><p><strong>Description</strong><br />I am seeing this on QGIS 1.8 and on master (revision ee96d38) with a particular table. I think the problem occurs when the SRID of a field is different from the SRID of the data contained in the field. I encountered the issue when I loaded an unprojected shapefile (attached) into postgis, and then updated the srid with <code>UPDATE testdata SET geom=ST_SetSRID(geom,4326);</code> The result of <code>select find_srid('public','testdata','geom');</code> is then 0, but <code>SELECT DISTINCT ST_SRID(geom) FROM testdata;</code> returns 4326. Loading such a table into QGIS will result in the errors below.</p>
<p><strong>Error messages</strong><br /><pre>Fetching from cursor qgisf0 failed
Database error: ERROR: Operation on mixed SRID geometries
Query: CLOSE qgisf0 returned 7 [ERROR: current transaction is aborted, commands ignored until end of transaction block]
1 cursor states lost.
SQL: CLOSE qgisf0
Result: 7 (ERROR: current transaction is aborted, commands ignored until end of transaction block)</pre></p>
<p><strong>Steps to reproduce</strong><br />1. Load attached shapefile in postgis (postgis 2.0, postgres 9.1.8 on ubuntu 12.10):<br /><pre>shp2pgsql Grid50_RSA tempdata | psql -d <qgisdb></pre></p>
<p>2. Update the srid of all records in the table:<br /><pre>UPDATE testdata SET geom=ST_SetSRID(geom,4326);</pre></p>
<p>3. Load in new QGIS session (either 1.8 or master) using DB Manager<br />4. Try to identify a feature using identify features.</p>
<p><strong>Workaround</strong><br />1. Add a new geometry column to the table, eg<br /><pre>SELECT AddGeometryColumn('testdata','the_geom',4326, 'MULTIPOLYGON', 2);</pre></p>
<p>2. Transform the geometry to the new column, eg<br /><pre>UPDATE testdata SET the_geom = ST_Transform(geom,4326);</pre></p>
<p>3. Drop the old column:<br /><pre>alter table testdata drop column geom;</pre></p>
<p>4. Rename the new column to the old name:<br /><pre>alter table testdata rename column the_geom to geom;</pre></p>
<p>5. Check that the following two commands give the same result:</p>
<pre>
SELECT DISTINCT ST_SRID(geom) FROM testdata;
select find_srid('public','testdata','geom');
</pre> QGIS Application - Bug report #4470: cursor states lost with identify tool on postgis layerhttps://issues.qgis.org/issues/4470?journal_id=411772013-05-24T14:19:53ZJürgen Fischerjef@norbit.de
<ul><li><strong>Status</strong> changed from <i>Reopened</i> to <i>Closed</i></li></ul><p>Fixed in changeset <a class="changeset" href="https://issues.qgis.org/projects/qgis/repository/revisions/f990886b61d920cf1ef82d940413e56611bc5685" title="fix #4470 and #7889">f990886b61d920cf1ef82d940413e56611bc5685</a>.</p>