1

Is there a way to summarize string attributes using QGIS 3.0 without having to export to excel?

I have a point layer as an output of a spatial join. I would like to summarize the information so that it looks more like the "desired output" below using QGIS 3.0. (I recreated what I wanted out of QGIS for demonstrative purposes of what I am trying to do I'm QGIS).

I have tried multipart to singlepart (assume since points this does not work).

Tried the "list unique values tool" and either I don't know how to work the tool, or that is DEFINITELY not the answer.

enter image description here

bumped to the homepage by Community 2 days ago

This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.

  • So does this mean my question is not possible inside of QGIS? That alone is an answer. – Mary Johnson Apr 10 '18 at 11:33
0

You will need to create a new field with the combination of the two attributes that you want to be a unique row, for a later dissolve by that attribute.

If "ID1" and "ID2" are string fields, you can concatenate them (if they are numbers, you can convert them to string and concatenate in the same expression).

  • Create a new string type field (name it, i.e., ID1_ID2) and populate it with the expression: concat( "ID1", '_', "ID2") in the Field Calculator.

Each row of the table is a feature of the layer, if they are points returned by a spatial join, it is supposed that all features with the same "ID1" value are identical points. When you dissolve features, if they are spatially disjointed, they will be a multipart feature with more than one part; but if they are identical features they will have just one part (one point in this case).

  • Dissolve the layer, by the field "ID1_ID2".

The output is a new layer, with one feature for each distinct combination of "ID1" and "ID2".

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.