Tag Info

New answers tagged

4

The problem is that the dataset you are currently trying to use as the input feature layer is technically not a feature layer, it's a shapefile. What you need to do is use the Make Feature Layer tool on the shapefile, and then use the resulting feature layer for the selection process. It's a little confusing, but realize that when you add a shapefile into ...


5

I don't think you can remove features from a selection layer once it's been created, but the workaround that I usually use is to create a new selection layer from your existing one: Select the features in your selection layer that you want to remove. Open the selection layer's attribute table and click Switch Selection, which will make all the features ...


0

As far as I know, there's no way to add features to a layer created by selection. The easiest thing to do is select all the features that went into that layer, add the ones you want by manual selection or using Select by Attributes/Location with a 'add to current' method (see my answer at this question for working with active selections), and then create a ...


1

Solution: Make sure that the SRID's in the geometries match. The SQL MSDN Documentation states: STContains always returns null if the spatial reference IDs (SRIDs) of the SqlGeometry instances do not match. And sure enough, I get null. When I defined the polys I gave them an SRID of 0, so they matched and the query worked as expected. In my second ...


1

Along with T.Wayne's answer, your SQL looks funky as well. You may want to try: "\"CLASS_NAME\" IN ('item1','item2','item3')" This SQL will select all features with either item1, item2, or item3 as its CLASS_NAME field value. or: '"CLASS_NAME" = \'item1,item2,item3\'' This SQL will select all features with item1,item2,item3 as its CLASS_NAME field ...


2

>>> outPoly = "C:\output\newpoly.shp" >>> print "'{0}'".format(outPoly) 'C:\output ewpoly.shp' >>> >>> outPoly = r"C:\output\newpoly.shp" >>> print "'{0}'".format(outPoly) 'C:\output\newpoly.shp' >>> This probably explains it best: https://docs.python.org/2.0/ref/strings.html


1

The sidebar in Google Earth lets you use the mouse to drag/drop items like polygons. You should be able to click & hold on one of your Untitled Polygons, move the mouse pointer up to the desired location in your My Places, and then release the mouse button to "drop" the polygon into that new location. In future, first select the folder where you want ...


2

You can use Foreign Data Wrappers, as of Postgres 9.2 (I think), from within Postgres to register a connection to another data source, either a Postgres server on another machine, or a completely separate data source. CREATE EXTENSION postgres_fdw; CREATE SERVER foreign_spatial_lite FOREIGN DATA WRAPPER postgres_fdw OPTIONS (dbname 'some_dbname', ...


0

You can only connected to one (and only one) database in the DB Manager to run the SQL window. So this is not possibly. Either your way of cloning the data, or making the join inside QGIS in the Properties > Joins tab of one of the layers.



Top 50 recent answers are included