Skip to main content

Questions tagged [virtual-layer]

A QGIS vector layer that is a database view built using SQL over other QGIS layers.

Filter by
Sorted by
Tagged with
0 votes
0 answers
45 views

When I create a virtual layer, my SQL code needs to allow for the summation of an entity's surface area based on a condition applied to another field of the same entity. This condition is expressed in ...
user335194's user avatar
1 vote
0 answers
51 views

I have 2 tables in a geopackage with a 1:many relationship: -- parent table CREATE TABLE "str_pt" ( "fid" INTEGER NOT NULL, "geometry" POINT, "...
Phillip Allen's user avatar
0 votes
0 answers
72 views

I am using QGIS 3.42.1. I have a virtual layer consisting of a join between 3 PostGIS tables to connect a customer with a location. location_customer_address: SELECT a.location_name, c....
JonBonGPS's user avatar
2 votes
1 answer
146 views

I find the normal possibilities for label placement on contour lines aesthetically chaotic. I would like to have a way to place the labels on the ridgelines and waterlines. I have done manual ...
gotjosh's user avatar
  • 399
1 vote
1 answer
76 views

I was puzzled to find that the st_segmentize function is not available to QGIS Virtual Layers. Is there a workaround? I need to split my line into equal length segments, like with st_segmentize(...
Kay's user avatar
  • 1,894
3 votes
0 answers
86 views

As I'm already aware, QGIS 3.30+ has a built-in "Split with Lines" tool. However, a variant specifically tailored for the SQL Virtual Layer system, particularly one built around the ST_Split(...
Routhwick's user avatar
  • 111
1 vote
1 answer
126 views

Using QGIS, I´ve created a point geopackage layer (punkte_gnss) and two virtual layers (pGNSS_vL_PvDW,pGNSS_vL_CircleIntersect). Both with separate expressions and symbology/textstyling. But both with ...
Sickculture's user avatar
2 votes
1 answer
117 views

I am looking for a very similar solution to the one for polygons but for a simple line layer and with some additional data included on the points: elevation from a DTM (available as a layer in the ...
gotjosh's user avatar
  • 399
0 votes
0 answers
61 views

Is it possible to combine a virtual layer with a layer in group? For my project: I create a group "A" place a point layer "A" place a virtual layer "A" with a little ...
Sickculture's user avatar
1 vote
0 answers
53 views

While export offline with QField sync I´m getting follow error: CRITICAL Layer vlayer : Error while executing feature count request : Query preparation error on SELECT Count(*),Min(MbrMinX("&...
Sickculture's user avatar
-1 votes
1 answer
130 views

I´ve build a little project with a point layer and a virtual layer. I´ve import the layer from the procet to the virtual layer and add some code. This will create a buffer zone around my point layer. ...
Sickculture's user avatar
4 votes
1 answer
472 views

I keep getting "Referenced table C:\Users\IA\Documents\QGIScsvtest1.csv in query not found!" fault message when trying to read a CSV. I go to create a virtual layer (I want to keep the CSV ...
IngemarA's user avatar
1 vote
1 answer
96 views

I have a geopackage with 25 million points and the little laptop that could. The attribute table has a speed and a location identifier for each point. We can call the fields "Speed" and &...
Stuart Miller's user avatar
3 votes
2 answers
221 views

I have two line layers in QGIS, of which one layer (layer 2 - yellow in the image) is a geometrical subset of the other (layer 1- blue in the image). The two layers also differ in their values of a ...
i.i.k.'s user avatar
  • 1,933
4 votes
1 answer
128 views

I've got a problem JOINing together several PostGIS tables (with or without geometry) in a Virtual Layer in QGIS 3.36.3 As soon as I use a (inner) join the the layer query statement, the result set is ...
Tom's user avatar
  • 53
0 votes
0 answers
64 views

I want to create a virtual layer with a fixed buffer distance e.g. 1000 m from a buliding layer as input. The building layer contains information about its use in colum X of its attribute table. The ...
Kevin_S2021's user avatar
3 votes
1 answer
265 views

I recently posted this question, where the answer involved SQL and a Virtual Layer. In that situation, the SQL acted on the entire input layer, with the output exactly as desired. Now I would filter ...
Stu Smith's user avatar
  • 7,938
0 votes
0 answers
120 views

Migrating from 3.28 to 3.34.5 I have a virtual layer that is causing crashes. I am using a virtual layer to union 3 layers together to simplify the number of layers. I have simplified the layer and it'...
Sethinacan's user avatar
  • 2,360
0 votes
0 answers
71 views

I am creating a QGis project to help us track regular visits to specific properties in a small area. In order to do that I have the property cadastre layer which contains around 10000 individual ...
Cristian's user avatar
2 votes
1 answer
85 views

From 3 tables with the following fields: PARENT_TABLE CODE1 CODE2 XCOORD XCOORD 12395 8604813EG7180S0001GX 418477,91 4620364,53 13505 8604813EG7180S0001GX 418477,91 4620364,53 12968 ...
Acperience's user avatar
  • 1,162
3 votes
1 answer
292 views

From a table with the following fields: CODE1 CODE2 XCOORD YCOORD 162 6605548EG7180N0001SF 418596,65 4620206,74 196 6604802EG7180S0001SX 418477,91 4620364,53 196 6604802EG7180S0001SX 418477,91 4620364,...
Acperience's user avatar
  • 1,162
3 votes
1 answer
150 views

I'm using QGIS 3.28 on Windows. I'm trying to make a workflow for determining whether a proposed lot satisfies minimum lot sizing based on soil type composition. I have: a single-polygon overall ...
dsjeffery's user avatar
2 votes
1 answer
38 views

Background: Sometimes in modelling hydrology (e.g. in SWMM) we have runon from one subcatchment area to another. These subcatchments are records in a shapefile. I want to show this situation as a line ...
Michael Kitchen's user avatar
1 vote
0 answers
92 views

Is there an equivalent to ST_Project that I can use for an SQL query for a virtual layer in QGIS https://www.gaia-gis.it/gaia-sins/spatialite-sql-4.2.0.html ST_Project( start_point Geometry, distance ...
Sethinacan's user avatar
  • 2,360
3 votes
0 answers
138 views

I have some expressions for drawing tree canopy zones ultimately I want to merge the zones for trees, hedges and woodland together but for now I would be happy if I can get the following expression to ...
Sethinacan's user avatar
  • 2,360
1 vote
1 answer
87 views

I have a 'POINTS' layer with 74 points geometry with the fields "NAME" and "ID". I want to add a virtual layer with the following query to calculate the clusters using the DBSCAN ...
Acperience's user avatar
  • 1,162
3 votes
1 answer
97 views

I have a polygon layer with classifications ('class'), and a second polygon layer of area of interest ('AOI'). I am trying to calculate the area of each of three classes within each (overlapping) AOI ...
Brian Fisher's user avatar
  • 1,197
1 vote
1 answer
54 views

I have point data within an MS SQL Server. I can add it as a layer to QGIS by creating a DB connection under MS SQL Server and double clicking the table listed. I also have a polygon layer again added ...
James Bourne's user avatar
1 vote
0 answers
59 views

To extract useful data from CSV file I use virtual layer. As virtual layer are based on SQLite all field in my virtual layer are of type int, real or text. These data need to be exported in an ESRI ...
J.R's user avatar
  • 18.3k
3 votes
0 answers
116 views

I want to update a virtual layer using PyQGIS by modifying the layer name in the query. Although I have executed the following code, the virtual layer's query remains unchanged when I open the project ...
user234164's user avatar
5 votes
1 answer
298 views

I am trying to create a virtual layer in QGIS that is the intersection of two polygon layers, "Cowardin" and "Wetlands". Both layers are in the map canvas in the same projection (...
Brian Fisher's user avatar
  • 1,197
3 votes
0 answers
334 views

If have an input layer with a couple of lines, called Line with an attribute. I would like to have a virtual layer with alle connecting lines dissolved, regardless of the attribute. input: expected ...
Beni's user avatar
  • 406
3 votes
1 answer
349 views

I created a simple virtual layer in QGIS, combining a couple of points from a polygon layer with vertexes from a polygon layer. I would like to export that virtual layer to be used as dynamic virtual ...
Beni's user avatar
  • 406
2 votes
2 answers
171 views

i've defined the following SQL statement in the query editor of qgis' db manager: select sd.fk_polyg, count(sd.fk_polyg), STRING_AGG(DISTINCT sl.typ, ', ') as concat_typ from schaden_stein_detail as ...
robert tuw's user avatar
3 votes
1 answer
372 views

In QGIS I have a virtual layer which does a line generation based on a point shape. The point shape has about 700 point geometries and 26 attribute fields. SELECT a.Name, a.FromNode, a.ToNode, a....
MtoK's user avatar
  • 61
2 votes
1 answer
80 views

I have already viewed this link and still having issues - Creating Virtual Layer with PyQGIS. When I create a virtual layer from the Layer -> Add/edit virtual layer and use this as a query it ...
heckubiss's user avatar
2 votes
1 answer
457 views

I've been using PostGIS' ST_DumpPoints to 'explode' multipolygon layer into points with its corresponding polygon part, ring and index information. As QGIS uses a SpatiaLite engine against its Virtual ...
EranGeo's user avatar
  • 1,182
2 votes
1 answer
428 views

I am trying to use a virtual layer in QGIS (3.30) to add a region field to a suburb layer, by locating the centroid of the suburb within a region. The general approach is taken from: Spatial join ...
Tom Brennan's user avatar
  • 6,256
3 votes
1 answer
78 views

I have a set of lines consisting of several single object LineStrings. These line can be collected to routes by attribute, e.g. a street consisting of multiple lines from crossing to crossing, but ...
e-shirt's user avatar
  • 845
2 votes
1 answer
192 views

I've created start and end points from a LineString layer using this answer from another question: select id, sts as route_id, st_endpoint(geometry) as geometry from pointclasstest union select id, ...
e-shirt's user avatar
  • 845
1 vote
1 answer
150 views

I have a point layer "Points" with the following attributes: Name FromNode ToNode Startheight Gradient Length Endheight 14870040 14870040 14870055 39 0.005 57.51 14870056 14870056 18880033 0 ...
MtoK's user avatar
  • 61
5 votes
2 answers
291 views

I've got a QGIS point geometry layer with four point features and a numeric field sequence. I want to create a virtual layer joining these points into a line geometry layer (which will have one ...
Spacedman's user avatar
  • 69.4k
3 votes
1 answer
213 views

I have many grids in shapefile format. Adding alphanumeric labels to them can be done through using a virtual layer SQL query as found in this thread: Creating GRID with customized labels in QGIS, ...
Bryce01's user avatar
  • 33
1 vote
0 answers
61 views

I would like to create vector points for each pixel of a raster that is located in polygon, using a Virtual layer. Details : I have 2 layers: P : vectors layer of polygons R : raster with value in ...
zlikotp's user avatar
  • 54
1 vote
1 answer
183 views

I would like to create a virtual layer that creates polygons and make some raster zonal statistics in the geometry of these polygons. The aim is to use the polygons geometry to analyze pixel values of ...
zlikotp's user avatar
  • 54
4 votes
2 answers
273 views

I would like to automatize the creation of several singlepart polygons when polygons (from layer Polygons) are crossed by a the same polyline (from layer polylines), and fill the gap between like ...
zlikotp's user avatar
  • 54
2 votes
2 answers
349 views

I'm trying to create a virtual layer in QGIS for use in QField using SQL, but cannot work out what the syntax is to refer to a GeoPackage layer. My GeoPackage is named "survey". My ...
Oisin's user avatar
  • 1,989
2 votes
0 answers
84 views

I am trying to extract the areas of several land cover classes within a buffer polygon, and want them to change when the underlying polygons are edited. My current work flow is: edit polygon buffer ...
Brian Fisher's user avatar
  • 1,197
0 votes
1 answer
60 views

I have scripted a workflow in ArcGIS Pro where a set of rasters gets some new data for certain areas, which is updated by building a Mosaic Dataset where the new rasters are layed on top of the old ...
MoritzMoreira's user avatar
1 vote
0 answers
178 views

I have a Spatialite database with three tables. I'd like to draw a center point of a line (by using ST_Line_Interpolate_Point) that is generated by a multi table join. The first table has the ...
Pixelfahnder's user avatar

1
2 3 4 5