-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Field Calculator: Nonsense values for $area and $perimeter #17334
Comments
Author Name: Giovanni Manghi (@gioman) can you please attach sample data? This issue surfaced recently or it was already there in previous master/dev releases pre-2.0? |
Author Name: Giovanni Manghi (@gioman)
|
Author Name: Paolo Cavallini (@pcav)
|
Author Name: Bernd Vogelgesang (Bernd Vogelgesang) Here my simple layer: Don't know which version i used last time to calcualte $area. Just realized then that it doesn't handle multi-part object correctly.
|
Author Name: Giovanni Manghi (@gioman) I tested your vector with qgis 1.9 on linux a few days old, and with qgis 2.1 on Windows: I cannot confirm this issue, in both cases the results are identical to the ones computed by qgis 1.8 by you. See attached file.
|
Author Name: Bernd Vogelgesang (Bernd Vogelgesang) On my computer at home, this didn't happen as well. Today reinstalled QGIS from scratch, loaded the project and tried again. The same error occured. Update: So, it definately doesn't work with on-the-fly transformation for this shape! |
Author Name: Giovanni Manghi (@gioman)
ok confirmed. So... in QGIS 1.8 works as expected even when reprojecting? |
Author Name: Giovanni Manghi (@gioman)
oh yes... so this is a BAD BAD regression...
|
Author Name: Bernd Vogelgesang (Bernd Vogelgesang) just to clarify: there was nothing to reproject. The layer and the project was in the same CRS. The difference was made activating or deactivating on-the-fly transformation for the project. Update: I have no idea what can go wrong with a shape file. This one was created in an environment (presumingly under 1.8 or 1.9, I often switch) with layers in EPSG 4326, 31468 and 3857. But sth must have changed in QGIS behavior as well: When i load the layer in 1.8 in a fresh project, the project crs switches to 31468, while in 2.1 it stays in 4326. Hope s.o. will figure it out. |
Author Name: Giovanni Manghi (@gioman) Bernd Vogelgesang wrote:
I confirm the issue also with other projections that I'm more familiar with, like 3763. |
Author Name: Bernd Vogelgesang (Bernd Vogelgesang) I have to report that this issue also occurs with 2.01 stable, so not only master is affected. |
Author Name: Jürgen Fischer (@jef-n)
|
Author Name: Giovanni Manghi (@gioman) Bernd Vogelgesang wrote:
I confirm it seems fixed in qgis master. If no backports are expected then should not this be closed? |
Author Name: Paolo Cavallini (@pcav) If this works in master, it can indeed be closed. Reopen if necessary.
|
Author Name: Giovanni Manghi (@gioman) Paolo Cavallini wrote:
it is not fixed, but anyway there is another ticket about it. |
Author Name: Bernd Vogelgesang (Bernd Vogelgesang)
Original Redmine Issue: 8592
Affected QGIS version: 2.0.1
Redmine category:vectors
Calculating an area field for a polygon layer in todays 2.1-dev from osegeo4w, the field is filled with strange 9-digit numbers, positive or negative ones, or zero.
Done this with a polygon layer in DHDN-Gauss-Grüger 4, 1.8 correctly calculates the value e.g 334325 while in 2.1, the preview of the calulator shows the same value, but fills in 0.
Other values:
187868 -> -139069743
92118 -> 109699764
Tried it both with integer and decimal fields.
Just tested also $peremiter: same strange numbers in comparison to 1.8
Related issue(s): #17453 (relates)
Redmine related issue(s): 8738
The text was updated successfully, but these errors were encountered: