Skip to content
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

Aggregate function bug on macOS version #32932

Closed
giovanniborga opened this issue Nov 18, 2019 · 15 comments
Closed

Aggregate function bug on macOS version #32932

giovanniborga opened this issue Nov 18, 2019 · 15 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Feedback Waiting on the submitter for answers macOS

Comments

@giovanniborga
Copy link

Bug description:
Note that it occurs ONLY WITH MACOS VERSION of QGIS.
For numeric fields, setting "first_value" on aggregate function inside AGGREGATE process dialogue doesn't take effect. Processing tool returns always SUM of numeric values.

How to Reproduce:

  1. Open a new project on a QGIS MACOS System
  2. Add a vector layer
  3. Choose Vector Geometry -> Aggregate from Geoprocessing Tools panel
  4. Set input layer and a numeric field as aggregate field
  5. Set some aggregate functions for existing fields
  6. Set "first_value" for the field used in step 4 to get references for results dataset rows
  7. execute
  8. check result: values in filed used in step 4 are summed instead of first_values

QGIS and OS versions:
All 3.x versions (until 3.10) for MAC OS.

@giovanniborga giovanniborga added the Bug Either a bug report, or a bug fix. Let's hope for the latter! label Nov 18, 2019
@gioman
Copy link
Contributor

gioman commented Nov 18, 2019

it works as expected on other platforms?

@gioman gioman added the Feedback Waiting on the submitter for answers label Nov 18, 2019
@giovanniborga
Copy link
Author

Yes. On Windows it works perfectly!

@gioman
Copy link
Contributor

gioman commented Nov 18, 2019

Yes. On Windows it works perfectly!

is data dependent?

@giovanniborga
Copy link
Author

do you mean "data-type" dependant?

@gioman
Copy link
Contributor

gioman commented Nov 18, 2019

do you mean "data-type" dependant?

also, but also if it happens with specific datasets rather than any dataset.

@giovanniborga
Copy link
Author

I teach GIS from several years ... having students with both Windows and MAC OSes. I think I saw this bug about almost 3 years ago and it has never been solved (I suppose few persons encountered it).
I used different datasets and everytime I encountered the bug so, yes, I think it happens with any dataset... I don't know if the bug occurs on string fields; I remember only that numeric fields were always summed instead of selected the first value … (I cannot reproduce the bug now because I'm a MS user)

@gioman
Copy link
Contributor

gioman commented Nov 18, 2019

so, yes, I think it happens with any dataset.

just to be sure an you attach a dataset where you observe this? thanks.

@giovanniborga
Copy link
Author

giovanniborga commented Nov 18, 2019

buildings.zip
Today we worked with this tiny layer.
Just aggregate by "zones_id", compute count of "NUMERO", sum of "volume" and first of "zones_id".
MAC users just had zones_ids summed instead of first_selected.

… But I really suppose it occurs with any other dataset ...

@gioman
Copy link
Contributor

gioman commented Nov 18, 2019

@giovanniborga for what is worth, I get expected results on Linux/QGIS 3.4. I can't test on macOS.

@DelazJ
Copy link
Contributor

DelazJ commented Nov 19, 2019

I'm afraid the issue is worse. Here's the settings in the aggregates dialog, using Mojave
image
Here's the call when it's executed
image

Everything is about SUM though I asked none

@giovanniborga
Copy link
Author

I supposed it was so ...

@3nids 3nids added the macOS label Nov 20, 2019
@gioman
Copy link
Contributor

gioman commented Jan 8, 2020

I also see this now that I can test on macOS...

@gioman gioman removed the Feedback Waiting on the submitter for answers label Jan 8, 2020
@gioman
Copy link
Contributor

gioman commented Jan 8, 2020

For a quick check compare to results given by the "group stats" plugin.

@gioman gioman changed the title Aggregate function bug on MACOS version Aggregate function bug on macOS version Jul 6, 2020
@PeterPetrik
Copy link
Contributor

Cannot replicate with the latest master anymore https://qgis.org/downloads/macos/nightly/qgis_nightly_master_20201005_122844.dmg

Screenshot 2020-10-06 at 14 39 44

Screenshot 2020-10-06 at 14 40 12

@PeterPetrik PeterPetrik added the Feedback Waiting on the submitter for answers label Oct 6, 2020
@gioman
Copy link
Contributor

gioman commented Dec 21, 2020

Closing for lack of further feedback.

@gioman gioman closed this as completed Dec 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Feedback Waiting on the submitter for answers macOS
Projects
None yet
Development

No branches or pull requests

5 participants