https://issues.qgis.org/https://issues.qgis.org/favicon.ico2014-10-24T06:13:32ZQGIS Issue TrackingQGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567032014-10-24T06:13:32ZGiovanni Manghigiovanni.manghi@gmail.com
<ul><li><strong>Subject</strong> changed from <i>Copy column type</i> to <i>copy string attribute into another one changes the length of the terget column</i></li><li><strong>Priority</strong> changed from <i>Normal</i> to <i>Severe/Regression</i></li><li><strong>Operating System</strong> deleted (<del><i>windows</i></del>)</li><li><strong>OS version</strong> deleted (<del><i>7</i></del>)</li><li><strong>Affected QGIS version</strong> changed from <i>2.4.0</i> to <i>master</i></li></ul><p>I'll tag this a regression unless this is one more strange intended behavior, like <a class="issue tracker-1 status-5 priority-10 priority- closed" href="https://issues.qgis.org/issues/11487" title="Dividing integer with integer gives wrong result (if operation is supposed to return a decimal) (Closed)">#11487</a></p>
<p>I confirm that copying the content of a string column into another string column will "stretch" the second one to accommodate the content of the first one.</p>
<p>Right after doing the operation, in "vector properties > fields" will show the supposed lenght of the second column, but if you remove and re-add the shapefile then a different length will show, the one of the first column!</p>
<p>Creating the second column directly in the field calculator, or adding one empty before hand does not make any difference.</p>
<p>QGIS 1.8 worked as expected (again, if this new behavior is not considered intended).</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567322014-10-24T23:50:35ZJürgen Fischerjef@norbit.de
<ul><li><strong>Subject</strong> changed from <i>copy string attribute into another one changes the length of the terget column</i> to <i>copy string attribute into another one changes the length of the target column</i></li></ul> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567432014-10-25T03:38:03Zaperi2007 -aperi2007@gmail.com
<ul></ul><p>I dont understand well.</p>
<p>this bug is also in qgis 2.4 and 2.2 ?</p>
<p>Just to understand if is a blocking issue.<br />AFAIK the blocker are only the bugs that are not on qgis 2.4</p>
<p>A.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567462014-10-25T04:29:18ZGiovanni Manghigiovanni.manghi@gmail.com
<ul></ul><p>aperi2007 - wrote:</p>
<blockquote>
<p>I dont understand well.</p>
<p>this bug is also in qgis 2.4 and 2.2 ?</p>
<p>Just to understand if is a blocking issue.<br />AFAIK the blocker are only the bugs that are not on qgis 2.4</p>
<p>A.</p>
</blockquote>
<p>Until qgis 1.8 this was not an issue, then I tested that any 2.* release is affected.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567472014-10-25T04:33:32Zaperi2007 -aperi2007@gmail.com
<ul></ul><p>SO this could not be consider a blocker issue.</p>
<p>All the user of qgis 2.2 or qgis 2.4 just now live with this feature.</p>
<p>A.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567482014-10-25T04:34:55Zaperi2007 -aperi2007@gmail.com
<ul></ul><p>oops , I wrong to writ.<br />Dont feature, but issue.</p>
<p>rewrite:</p>
<p>SO this could not be consider a blocker issue.</p>
<p>All the user of qgis 2.2 or qgis 2.4 just now live with this issue.</p>
<p>A.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567502014-10-25T04:49:32ZGiovanni Manghigiovanni.manghi@gmail.com
<ul></ul><p>aperi2007 - wrote:</p>
<blockquote>
<p>oops , I wrong to writ.<br />Dont feature, but issue.</p>
<p>rewrite:</p>
<p>SO this could not be consider a blocker issue.</p>
<p>All the user of qgis 2.2 or qgis 2.4 just now live with this issue.</p>
<p>A.</p>
</blockquote>
<p>I have to report all regression as blockers, then if one of the devs wants to downgrade it is his decision.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567732014-10-26T01:45:54ZAlessandro Pasotti
<ul></ul><p>Confirmed.</p>
<p>This bug report lacks a fundamental information: the expected behaviour.</p>
<p>I'm not sure about what it should be:</p>
<p>1. abort the operation, failing to create the column with an error message that the data will not fit into the newly created field<br />2. create the column, automatically expanding the width to contain the longest string and issue a warning<br />3. create the column truncating the strings and issue a warning<br />4. actual behaviour (like 3 but without warning, I guess)</p>
<p>I would really prefer n. 2, in that case, this bug report would be only about a missing warning message.</p>
<p>BTW I don't really see this as a blocker, it seems more like a feature than a bug to me.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=567752014-10-26T01:58:54ZGiovanni Manghigiovanni.manghi@gmail.com
<ul></ul><blockquote>
<p>This bug report lacks a fundamental information: the expected behaviour.</p>
</blockquote>
<p>:)</p>
<blockquote>
<p>I'm not sure about what it should be:</p>
<p>1. abort the operation, failing to create the column with an error message that the data will not fit into the newly created field<br />2. create the column, automatically expanding the width to contain the longest string and issue a warning<br />3. create the column truncating the strings and issue a warning<br />4. actual behaviour (like 3 but without warning, I guess)</p>
<p>I would really prefer n. 2, in that case, this bug report would be only about a missing warning message.</p>
</blockquote>
<p>2 would be good, but as an option. There are good reason a user wants a column to be and remain of a certain length.</p>
<blockquote>
<p>BTW I don't really see this as a blocker, it seems more like a feature than a bug to me.</p>
</blockquote>
<p>as I said blockers are regression, unless of course is a known/documented change of behavior. This is not the case. This is new, undocumented and certainly something not expected as any other gis packages does not do that (that I'm aware of, of course).</p>
<p>Said that then the common sense must be used, a regression could be perfectly not harmful with no need to fix it in a hurry before a release.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=568662014-10-27T07:23:33ZMartin Dobiaswonder.sk@gmail.com
<ul><li><strong>Priority</strong> changed from <i>Severe/Regression</i> to <i>Normal</i></li></ul><p>Obviously this is a new feature in OGR's Shapefile driver - from <a class="external" href="http://www.gdal.org/drv_shapefile.html">http://www.gdal.org/drv_shapefile.html</a></p>
<p>"Starting with GDAL/OGR 1.10, the driver knows to auto-extend string and integer fields (up to the 255 bytes limit imposed by the DBF format) to dynamically accomodate for the length of the data to be inserted."</p>
<p>Is this a bug in the end? :-)</p>
<p>Please feel free to close - for the meanwhile I'm lowering the priority.</p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=569352014-10-29T11:35:29ZGiovanni Manghigiovanni.manghi@gmail.com
<ul><li><strong>Category</strong> changed from <i>Attribute table</i> to <i>Documentation and Help</i></li><li><strong>Tracker</strong> changed from <i>Bug report</i> to <i>Feature request</i></li></ul><p>Martin Dobias wrote:</p>
<blockquote>
<p>Obviously this is a new feature in OGR's Shapefile driver - from <a class="external" href="http://www.gdal.org/drv_shapefile.html">http://www.gdal.org/drv_shapefile.html</a></p>
</blockquote>
<p>it os obvious now that we know it :)</p>
<blockquote>
<p>Is this a bug in the end? :-)</p>
</blockquote>
<p>of course no, but this must be documented in qgis because I feel that users will be puzzled by this change and most of them will not go look in underlying libraries docs.</p>
<p>The description in ogr notes seems ok</p>
<p><strong>"Starting with GDAL/OGR 1.10, the driver knows to auto-extend string and integer fields (up to the 255 bytes limit imposed by the DBF format) to dynamically accomodate for the length of the data to be inserted."</strong></p> QGIS Application - Feature request #11485: copy string attribute into another one changes the length of the target columnhttps://issues.qgis.org/issues/11485?journal_id=597912015-03-05T05:59:40ZAlexander Bruy
<ul><li><strong>Status</strong> changed from <i>Open</i> to <i>Closed</i></li></ul><p>Moved to GitHub issues, see <a class="external" href="https://github.com/qgis/QGIS-Documentation/issues/480">https://github.com/qgis/QGIS-Documentation/issues/480</a></p>