Questions tagged [select-by-attribute]

To select data records according to logical criteria applied to their field values ("attributes")

Filter by
Sorted by
Tagged with
2
votes
1answer
777 views

SQL / Select by Attributes query for “does not include text found in another specified field”

I'm using ArcMap 10.2 and I'd like to write a query to select features where Field A does not include text found in Field B. Specifically, Field A contains street numbers and street names. Field B ...
2
votes
1answer
2k views

Using Select Layer By Attribute in ArcGIS ModelBuilder multiple times?

I want to use Select Layer By Attribute in ArcGIS ModelBuilder multiple times. It works everything fine until a new feature is created (e.g. after Dissolve or Multipart to Singlepart). Then I can't ...
2
votes
2answers
642 views

QGIS keyboard shortcut to launch a 'Select by expression' query

I can't find if it is possible to launch a 'Select by expression' query (not to open the dialog) with a keyboard shortcut. I can't find this option in the Settings > Configure shortcuts list... If ...
2
votes
1answer
888 views

Getting attributes from a lyr file

I have downloaded a crime dataset from imaps, an online GIS server for Raleigh, NC. The dataset shows the location and types of crimes in the past 90 days. Using the info tool, I can see all of the ...
2
votes
2answers
1k views

Why can't I use SelectLayerByAttribute_management while a cursor is set

I've been having a problem with arcpy in that the simple line: arcpy.SelectLayerByAttribute_management ("TEMP_LINES") produces this response: Runtime error : ERROR 000358: Invalid expression Failed ...
2
votes
1answer
525 views

Easy Extraction of features from a Feature dataset ( Not feature class)

My Feature dataset (residing inside a GDB) contains more than 30 feature classes and every month I like to extract features from this GDB based on one attribute, which is repeating in all the feature ...
2
votes
2answers
754 views

Trying to use an integer in a WHERE clause

I'm trying to use an integer value in a WHERE clause (looking at an integer field). expression = "'SERVICE' = 'Service' " expression = expression + 'AND ' expression = expression + "'GPS_TIME_TOTAL' &...
2
votes
2answers
1k views

Model builder: select feature based on attribute, iterator?

This is the data I have: shapefile with polygons shapefile with line features What I eventually want: line features attributes joined to the polygons that they fall in. I need to clip each polygon ...
2
votes
2answers
109 views

Selecting latest date by expression

I am trying to select the latest date by expression in QGIS. I tried to use this code "Date"= maximum("Date"). But nothing was selected. I wonder what is the right expression code to select the ...
2
votes
1answer
32 views

Select by character limit

I'm using the select by attributes to find unique values that I am copy pasting from a spreedsheet. EX "jobnumber" = 1111116 OR "jobnumber" = 2222245 OR "jobnumber" = 5555655 .. etc The problem is ...
2
votes
1answer
87 views

Filtering a layer by an extracted feature?

I am currently getting quite frustrated writing the base of a longer script. What I would like to do currently is to extract an attribute from one layer and select rows in another layer based on an ...
2
votes
1answer
2k views

How do I Cluster by an Attrbute?

I'm making a Leaflet map, and using the Marker Cluster plugin to cluster a Few Thousand Markers. On of the attributes in my Data is the State that this marker lies in. I would like that at the ...
2
votes
1answer
2k views

QGIS: How to modify the appearence of selected attributes [duplicate]

I am using QGIS version 2.14.1 (Essen). When I open the attributes table of a layer, I select some data which is then highlighted in yellow on the map. I was wondering if it is possible to change the ...
2
votes
1answer
57 views

Arcpy tool attribute selection

I'm trying to make tool of change detection between two polygons layers by fields of initial state and final state. Everything is working except attribute selection, I would like user could choose ...
2
votes
1answer
513 views

How to select attributes by unicode field value?

I have an attribute table in QGIS 2.10 with a string field (myfield) and when I want to make a selection based on the unique values of this field I get no selection at all. >idxmyfield = mylayer....
2
votes
1answer
602 views

Using Search Cursor to calculate fields with records having a specific value

I'm a total beginner at programming and Python. I'm trying to select features by attributes and then field calculate in another field. In VBA it might look like this: If [Z1COMM] = "R" then [...
2
votes
1answer
373 views

Using SelectLayerByAttribute and Where Clause in ArcPy?

I'm trying to select the minimum value from a field to select and export that one feature to a temp shp so I can copy the field data from the point to a line. So far I have this: import arcpy from ...
2
votes
1answer
1k views

Using for loop to execute query in ArcPy?

I'm trying to provide the breakdown of fire detection for an area by sorting of confidence levels. The dataset has 12 files (one for each month in a year) with fire records which all have a column ...
2
votes
1answer
390 views

Arcpy SelectByAttributes and Show Selection

I understand that in order to do a SelectByAttribute in Python, you need to first convert the shapefile to a feature layer using the MakeFeatureLayer_management function, and run the SelectByAttribute ...
2
votes
2answers
1k views

How to select features in layer using dataset statistics (stdev and mean) and ModelBuilder?

I am trying to solve following problem. I need to select features from the shapefile by attribute in Model builder. The attribute should be a statistics which you can calculate by the tool :"Summary ...
2
votes
1answer
519 views

Select and zoom script for ArcPy?

I am attempting to make a simple select and zoom python script for my address points. Currently the script will complete successfully but will not select or zoom to the entered point. I am using two ...
2
votes
1answer
58 views

Select by attribute does not work on an indexed field

I came across an issue where I can no longer run a select by attribute on a field (In my example it is "Students_7") in a shapefile that previously worked. Even when I build the query using the wizard ...
2
votes
1answer
50 views

How to use SQL queries in arcpy.SelectLayerByAttribute?

I'm trying to select features from a layer that I know exist. I'm using SelectLayerByAttribute_management in arcpy. I have a layer that is properly defined earlier in the code named "tourmaline". I'm ...
2
votes
2answers
74 views

Selecting a very Large Number of Column Rows based on a comma separated list of numbers

I have managed to do a lot of work regarding point data in the wrong projection, I forgot to change CRS from user 1000005 to BNG before I saved the layer as BNG so now it thinks it is in BNG only it ...
2
votes
2answers
127 views

Create a Select by Attributes subquery from a locational selection in ArcGIS with multiple variables

I have a large shapefile of GPS points. Each point has a unique point ID number, but they are all part of different clusters, where each cluster has a unique cluster ID number (there is no overlap ...
2
votes
1answer
48 views

Relating a table to a point layers and exporting results in model builder?

Here are the data that I'm working with: Table: Standalone table from an OLE DB connection with a MS Access db 10,800 records with non-distinct account IDs Divided into 300 different categories ...
2
votes
3answers
962 views

Select by Attributes Crashes ArcGIS

I have a feature class that contains 131000 records. One of its fields (which was originally joined from a table) only has three possible values: null, 0, and 1. I have been trying to select the ...
2
votes
2answers
668 views

Save multiple selection sets in QGIS

I'm looking for a feature in QGIS but I am not sure if it exists. I don't know the name of such feature, but I call it multiple selection sets. It exists in TransCAD and I find it very useful. It ...
2
votes
1answer
2k views

Creating a layer after using SelectLayerByAttribute_management

Is it possible to use an existent layer to do a selection by attributes without having to use MakeFeatureLayer_management first? Because I already have a layer with the same name as the feature class "...
2
votes
2answers
289 views

Create multiple tables from distinct attribute category values using Model Builder

I've got a shapefile I would like to extract distinct values from an attribute field and have the output as tables based on those values. The shapefile is made of polygons representing parcels and ...
2
votes
2answers
52 views

Copying only shapefiles which have specific field attribute in another folder using ArcPy?

I have 100 shapefiles that all have 2 fields in common called Type2017 and Type2018. The whole of the fields have only one number (1 or 2 or 3). fo example, Type2017 = 1 or Type2018 = 2 I would ...
2
votes
0answers
165 views

Calculation of fastest path with in network analysis by qgis 3.0

I have a road network (with speed limit) and different points connected to the roads. I would like to measure the distance between several points along the roads. Basically I want to do shortest path ...
2
votes
1answer
165 views

Selecting polygons which contain majority of area from intersected layer by polygons using QGIS?

I have two polygons layers (a squares grid (blue in image) and a rectangles grid (green in image)). Because the different polygon sizes, different squares overlap with a single rectangle. I need to ...
2
votes
0answers
92 views

When selecting by attribute, unique values display only dots (…) [closed]

I'm using ArcMap 10.3. I haven't found any information as to why this may be an issue or the cause. Does anyone know why dots show up in the unique value box when I have values in the field in the ...
2
votes
0answers
73 views

Exporting attribute data from vector data by selecting object in QGIS?

I'm using QGIS (2.4.0), and i need to export the attribute data of the object i select (shapefile) to another file ( Excel, txt,...it is yet to be determined depending on the solution). I know how it ...
2
votes
0answers
362 views

How to move points to another polygon based on attribute? [closed]

I have a point layer and a grid cell/fishnet layer. Each point falls within a grid cell. Now I want to move some of the points to another (the nearest) grid cell based on an attribute that exists in ...
2
votes
0answers
806 views

Shapefile From Excel Sheet Crash When Selected Spatialy or By Attributes

Using ArcGIS 10.2, I am receiving an Excel sheet, on a daily basis, which contains 105 columns(Fields) and includes has X and Y values. For whatever reason (which I cannot understand) all data types ...
2
votes
0answers
324 views

How to program select by attribute unique values using ArcGIS silverlight API?

I'd like to create a select by attribute window in my webGIS using silverlight api . this is like select by attribute in arcgis desktop . i create select layer combobox ( cbolayers)and select fields ...
2
votes
0answers
295 views

Select a distinct attribute with maximum shape area

I am trying to manipulate a large dataset containing a lot of sliver polygons resulting from an overlay operations. (The eliminate tool is very time consuming to generalize them.) I identified the ...
1
vote
3answers
3k views

What is a SQL Query to all values in a column with Select by Attribute in ArcGIS? [closed]

I would like to select all values for an attribute using select layer by attribute to use in model builder and hopefully save the expression for automation purposes. If I have an attribute named ...
1
vote
3answers
452 views

Searching for NULL values in feature class table

I am looking for a way which I can search whole my feature class in ArcMap to find if has any NULL values on it. I know how can I do this with "Select By Attribute", but I am looking for a faster way ...
1
vote
2answers
490 views

Any way to clear selections from features in a map only if they have selected features?

While I know the clear selection tool exists in ArcMap, I am looking to produce a script that would only work if all selections are cleared from the start. I have added lines of code to clear ...
1
vote
4answers
7k views

Zooming to selected features with ArcObjects

I am trying to figure out how to set the active view extent to be able to view all the selected features on the ArcMap. The Map has only one layer. The features are filtered with attributes. Below ...
1
vote
2answers
2k views

Selecting Layer by Attribute using SQL and variable in ArcPy

I've had a good look around the site and haven't been able able to find any 'select by attribute' questions regarding string variables and how to integrate them into an SQL statement. In my particular ...
1
vote
2answers
103 views

Selecting by attribute using Python and a list

I have been using this script to select a feature using Python: layer = iface.activeLayer() layer.selectByExpression('\"Declividad\"= value', QgsVectorLayer.SetSelection) selection = layer....
1
vote
3answers
124 views

Invalid expression with string/text

I'm trying to use ArcPy and Python more since the ability to just point and click isn't that marketable. I've been using ArcPy for Select by Attribute. It works fine when I try to select attribute ...
1
vote
4answers
410 views

Unsupported Operand Type for Field Query

Following on from Correct SQL expression for SelectbyAttribute Tool, I have my code: import arcpy plantFile = r"U:\Users\K\Plants.shp" field = "UID" arcpy.MakeFeatureLayer_management (plantFile, "...
1
vote
1answer
232 views

Testing uppercase vs lowercase field values on the fly using ArcPy & Python?

I am trying to use the code below to allow testing of one field which contains mixed case against another field which contains uppercase only. I have read many many posts but they generally tend to ...
1
vote
2answers
1k views

How to Select By Location with matching attribute?

I have a whole bunch of overlapping polygons (buffers), I want to select with points only those poly's which: the point falls within; and the poly attribute matches the point attribute What would be ...
1
vote
4answers
9k views

How can you auto-populate field using spatial location of another feature and its attributes?

I want to auto-populate a field based on the spatial location of another feature's attribute. Add a point on top of a building. The point automatically adds the name of the building. This seems like ...

1 2 3 4 5 10