There is a polygon layer 'Union23' that was created with the "Union" tool.
Layer's attribute table includes the following values.
My effort is simply to aggregate those polygons by "FLAECHEID" field with the sum and count of a field "In_Value1" via a Virtual Layer. So I am using the expression:
SELECT
*,
SUM(In_Value1),
COUNT(In_Value1)
FROM
Union23
GROUP BY
"FLAECHEID"
However, I am getting really weird output and I do not understand why I am losing a part of geometry on the way? Any suggestions?
References:



*, am I right? – Taras Mar 12 '19 at 12:03Flaecheidbetween the spatial layer and the newly computed stat table - that would not contain any geometry - – JGH Mar 12 '19 at 12:14Join. thank you – Taras Mar 12 '19 at 12:18