New answers tagged

0 votes

Using variable input in select by expression does not work in QGIS Modeler

The issue is actually simpler, when using a variable and ones that depend on previous processes, switch from "Value" to "Pre-calculated Value" in the expression dropdown then wrap ...
  • 101
1 vote

Problem by rasterizing in QGIS 3.28.4

Your screenshot shows that your created a raster 1 pixel widht, 1 pixel height. Adapt resolution and units to get proper results.
  • 55.5k
1 vote

Fill nodata holes in discrete integer raster with majority value of adjacent pixels QGIS

Past self, you can use the Grass algorithm r.neighbors in QGIS to do this. First create a mask layer that is the inverse of the layer you want to fill. This means that all the NoData cells you want to ...
  • 2,119
2 votes

Set the background of a label such that it fits to a wrapped line in QGIS

If you know for sure that all your labels will have consistent length, you can make a custom background as an image file. Use GIMP or another software to create your background Choose Marker Symbol ...
  • 12.3k
0 votes

Set the background of a label such that it fits to a wrapped line in QGIS

Coming close to what you want: draw large enough text buffers:
  • 55.5k
0 votes

Use child's last values for new child feature

Use aggregate fuction array_agg() to collect all vitality-values, grouped by tree_id, ordered by date. Exclude the current feature (the one you want to update) with optional filter condition. This is ...
  • 55.5k
0 votes

Set a relative path for PDF linking to shapefile

Using QGIS expression with function file_path() and variable @layer, you get the path of the current layer: file_path (@layer). Concatenate this with the filename to get what you want, using function ...
  • 55.5k
2 votes

Join attributes by location won't sum values in QGIS

You would have to use the tool Join attributes by location (summary). Feel free to look at this tutorial
  • 37.9k
0 votes

How do I use the GDAL raster calculator in QGIS to calculate P using conditional equations based on pixel values in another layer?

I've done a lot of raster processing (mostly biophysical data like yourself) and in my experience, map algebra more complicated than result = map1 + map2 is very cumbersome in both QGIS and Arc, and ...
  • 411
1 vote

Which version of Python is installed in the OSGeo4W shell?

or other way from within the python console: import sys print('{}.{}'.format(sys.version_info.major,sys.version_info.minor))
  • 8,583
1 vote

Which version of Python is installed in the OSGeo4W shell?

Open an OSGEO4W command shell and type python --version or you can check in the installer which will show you the version that is currently and about to be installed.
  • 78.2k
0 votes

In Google Earth Engine, can I export a layer with visual parameters added to a GeoTIFF?

Define pixel size while exporting e.g. Export.image.toDrive({ image: image.visualize(visParams), scale: 30, ... });
0 votes

Map tips showing only path instead of pictures in QGIS?

You can experiment with the maptips to see how the string you are using parses out before you put it in the image tag. You can also construct the paths from variables like [% @project_folder %] to ...
  • 1,579
0 votes

Show images related to features in QGIS?

It works with "Forms" if you have an attribute for your image file. The pathname can be relative. In QGIS 3.30.0-'s-Hertogenbosch, I have a points layer with a field for a local filename, ...
  • 1,579
0 votes

Displaying images as part of multiattribute labels using QGIS

See here a tutorial by Totò Fiandaca: https://www.youtube.com/watch?v=Kckrr6M3t4A
1 vote

Use child's last values for new child feature

If your tree ID is alphanumerically sortable and always increasing, you can simply switch the date field to the tree ID field: attribute(get_feature('observations', 'tree_id', maximum("tree_id&...
  • 9,977
1 vote

Creating callout/balloon labels in QGIS

It is now (QGIS 3) possible using the Balloons label style Callout:
  • 61.3k
8 votes
Accepted

Filtering data containing numeric values in QGIS

Use the following expression with function regexp_match(). The Regular Expression \\d finds any digit. Use double backslashes, because in QGIS, Backslash characters must be double escaped ...
  • 55.5k
5 votes
Accepted

Choose all the files of a folder as an input to run a process in the model designer in QGIS

You can execute the model as a batch process. Press Run model and: I select all files with 72 in the name in this folder: The tricky part is to name the outputs. This expression replaces the input ...
  • 61.3k
1 vote

Using NTv2 gridfiles in QGIS >= 3.22.x LTR with proj 9.x

At least for Proj it seems to be possible to use a workaround and update the existing record UPDATE grid_transformation set grid_name='kanu_ntv2_mittelfranken.gsb' WHERE code = 15948; Now projinfo ...
  • 59.2k
3 votes

Tracing tool missing in QGIS 3.28.4

it is still there (QGIS 3.28.4, Windows 11)
  • 8,583
5 votes

Converting multiple fields with abbreviations to one field with full names in QGIS

I would recommend using arrays to concatenate your data, especially as you will have some blank/null results which will make typical concatenate (||) not work well and you would need to wrap each ...
  • 9,034
0 votes
Accepted

QGIS - Is there a way to filter contents of attribute table in report to features that have a matching attribute field value with report feature?

You can use @atlas_... functions in Report layouts too, as the Group layer apparently works identically to the atlas layer in regular map layouts. In the 'Filter with' expression dialog, the active ...
  • 9,034
1 vote

Could not commit changes to layer X

I was having the same issue of 'could not commit changes' after editing polygons in a shapefile. The only way I found around this was to copy the polygons into a new shape file, which seemed to ...
  • 11
1 vote

Gradient colour for lines

As of QGIS 3.30 (released early 2023) and probably a few versions earlier, the interpolated line style seems to allow gradient lines. The start and end values don't seem to matter for this use case. ...
1 vote

Using QGIS processing algorithms in C++

QgsApplication::processingRegistry()->addProvider( new QgsNativeAlgorithms( QgsApplication::processingRegistry() ) ); QgsProcessingContext context; context.setProject(QgsProject::instance()); ...
3 votes
Accepted

Importing latitude and longitude data for UK

The coordinates from the archive of weather stations are in WGS 84 project system. Try choosing this for your project (EPSG:4326). The CEDA web site tells you this if you look further, for example ...
  • 100
4 votes

Making points appear on top of lines in QGIS

Simple solution You can drag the point layer above the line layer in the Layers pane. More advanced solution Enable the Layer Order panel via View > Panels > Layer Order In the Layer Order ...
  • 12.3k
6 votes

WFS layer shows blank area, even though there is some information in attribute table

Unfortunately they have configured their service to contain all the geometries as GEOMETRYCOLLECTION datatype, that QGIS does not handle. Test with https://e-kartta.ouka.fi/TeklaOGCWebOpen/WFS.ashx?...
  • 59.2k
4 votes

WFS layer shows blank area, even though there is some information in attribute table

There appears to be an issue with the returned GML whether it be the default GML2, or the GML3 requested by QGIS; that is both of these requests give invalid responses: https://e-kartta.ouka.fi/...
  • 12.7k
0 votes

QuickOSM times out when running a query

Please upgrade to the latest version 2.2.1 of QuickOSM, the list of Overpass server has been updated.
  • 6,721
0 votes

QuickOSM timing out

Please upgrade to the latest version 2.2.1 of QuickOSM, the list of Overpass server has been updated.
  • 6,721
6 votes
Accepted

Check Geometries Plugin - attribute value in results

I guess it is the value of the "thinnes" parameter
  • 59.2k
0 votes

Why Travelling Salesman Problem plugin is not working in QGIS 3?

You can install it via zip file for QGIS 2 using the answer from: How do I install a plugin when I have the .zip file for it
1 vote

Why Travelling Salesman Problem plugin is not working in QGIS 3?

I'd recommend you to stick to ORS Tools plugin, as it supports, amongst other tools and functions, TravellingSalesmanProblem: https://github.com/GIScience/orstools-qgis-plugin
1 vote
Accepted

Run feature action from canvas for overlapping polygons

You can set the field used to display this value in the list of the identify tool for any layer. Each feature is described by the name of a field along with its value. This field is the one set in ...
1 vote

Converting multiple fields with abbreviations to one field with full names in QGIS

You might want to use the Field Calculator and tick the option "Create a new field", as in the following picture: One method could be simply using concat("FISH2","FISH3")...
0 votes

Using GRASS GIS/QGIS to georeference TIFFs in 3D space, vertically?

Has there been any updates to this issue? Trying to display cross sections from the QGIS Geoscience plug-in in QGIS2Threejs.
0 votes

How do I eliminate the black border on a georeferenced map layer?

The black borders occur if a NoData value is not assigned to the layer prior to georeferencing. A NoData value can be added to the layer using Raster>Conversion>"Translate (Convert Format)&...
2 votes

View more than three pictures in the image viewer of QGIS

I have used a different technique to solve the problem (though the full image doesn't appear and I have to scroll to see more). I added a new Tab for each of the photo. It solved part of my problem, ...
2 votes
Accepted

Expression to filter array of features based on relationship to another layer

Instead of IS NULL (because an empty array - i.e. [] - is not NULL), you probably want to filter by length of array. e.g. array_length( relation_aggregate( relation:= 'Developers', ...
  • 9,034
0 votes

PyQGIS - add ArcGIS Feature Service layer to QGIS including a query

While it does not exactly answer the question (because it is not adding the ArcGIS layer directly), the following approach may be useful for some people. The code builds up the ArcGIS Feature Server ...
0 votes

View KML Feed in QGIS

I got this to work by downloading the data rather than using the live view. At the top left of your screenshot, it says "Found 333 sites" and then there are two buttons. The first downloads ...
2 votes

Calculate transformation parameters from known common points

Try ogr2ogr https://gdal.org/programs/ogr2ogr.html with -gcp option -gcp <ungeoref_x> <ungeoref_y> <georef_x> <georef_y> Add the indicated ground control point. This option ...
  • 59.2k
5 votes

Convert Geopackage to Tab file in QGIS?

The issue is caused by the MapInfo TAB format itself and it is a documented behavior of the GDAL Tab driver https://gdal.org/drivers/vector/mitab.html#creation-issues The TAB File format requires ...
  • 59.2k
4 votes
Accepted

Adding parcel number to site when there are many sites in QGIS

I'm not sure I completely understand your question, but [add autoincremental field] in the qgis toolbox may be able to help you. It can take all fields with a specific value and assign numbers to each ...
6 votes

Adding parcel number to site when there are many sites in QGIS

You can use row_number and partition by site: --Create a test table drop table if exists public.test; create table public.test (id serial, siteid varchar(10)); insert into public.test (siteid) values ...
  • 61.3k
0 votes

How to select features based on layer intersection on QGIS?

Yes we can, see the pic for more details
  • 1
3 votes
Accepted

Shapefile saving in project home instead of last used folder in QGIS

Yes, I find this frustrating too. There is a code way to try and fix it which can be run at the python window or added as a macro - see instructions at this answer: import os from qgis.core import ...
  • 1,677
5 votes
Accepted

Create dashed line with standard length and standard interval

You can create the dash geometry based on your line layer by: Create points along geometries with a distance of 2.5 m Buffer them by 0.75 m Difference with your lines as input and buffers as overlay:
  • 61.3k

Top 50 recent answers are included