New answers tagged

1 vote

How to set default attribute values on a new line based on overlay_touches/nearest for start_point and end_point

With your first expression, if you are getting NULL in the preview when setting up the default expression, this is normal if you have no features in your layer (or if all of the existing features ...
user avatar
  • 7,329
7 votes
Accepted

QGIS - Connection Lines using geometry generator between 2 layers in a relation N-1

You can do this using array_foreach() function collect_geometries(array_foreach(string_to_array( "ID_UC" ), Use this expression on the 'concpoints' layer. collect_geometries(array_foreach(...
user avatar
6 votes

What is meant by 'current feature' when using the field calculator or expression builder in QGIS?

The current feature is the one you're doing the calculation for. If you e.g. selected a single feature on the layer and choose to only updated selected features, the area is only calculated for that ...
user avatar
  • 12.4k
2 votes

QGIS misidentifying fields attribute type

Single quotes ' are for strings, double " for fields. So you are trying to sum the strings 'MTO heat map_total' and 'MTO heat map grouping'. Change ' to " so QGIS understand you are ...
user avatar
  • 51.2k
6 votes
Accepted

Using QGIS field calculator to create an 'fid' column according to a value from another column

Hacky solution using the field calculator: array_find( array_agg( expression := to_int(substr("Row name", 5))*10*maximum("Col")+"Col", order_by := to_int(...
user avatar
  • 23.2k
0 votes

How can I use the values of a GDB coded value domain in QGIS

The function represent_value can be used in a QGIS expression to access the value of a coded value domain. For example: represent_value( "size" ) will return the value.
user avatar
  • 157
1 vote

Categorizing field and summing attributes for label in QGIS

Use QGIS expressions with the aggregate function sum(), grouping it by the common part of the "CFSAUID" attribute. For this, define an expression that returns this common part, here ...
user avatar
  • 40k
1 vote

QGIS Print Layout expression for selected features in project

If you use is_selected as part of an if statement, it might do what you need. If you want to see the other labels also - have a 2nd layer with labels, no symbols. Set the main (is selected test) ...
user avatar
1 vote
Accepted

"array_agg" function for label in atlas by inserting an expression in QGIS

you have to convert it to a string object: array_to_string(array_agg("Número","Alumnos"))
user avatar
  • 7,710

Top 50 recent answers are included