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

learn more… | top users | synonyms

1
vote
1answer
41 views

How to perform a spatio-temporal query in attribute table? [duplicate]

I am not good at programming, so I would ask for your understanding concerning my question. I have an attribute table that contains five columns which are: (Date, ID, Latitude, Longitude, Rainfall). ...
0
votes
2answers
60 views

How to handle list variable in a where clause

I am calling a list of names in from a text file and would like to use each of those to make new layers. I am running into an issue where I get "TypeError: cannot concatenate 'str' and 'list' objects" ...
0
votes
0answers
42 views

How to select records in a table based on attributes in related table

I am using ArcMap 10.1 and Python I have a list of addresses to geocode, but I want to thin the list because I only need a specific area of the addresses. I have a layer containing the streets in ...
2
votes
3answers
172 views

SQL expression error for Select Layer By Attribute

arcpy.MakeFeatureLayer_management("N05-12_Station2_JGD.shp","station_12") year=2012 arcpy.SelectLayerByAttribute_management("station_12","#",'"closing">=%d AND "opening"<=%d' % year) ...
0
votes
1answer
34 views

Selecting Features in ArcGIS based on their relation other layers

I am extremely new to GIS mapping and I'm trying to do what I believe would be relatively simple. I have two layers: one contains data on school locations in Chicago and the other contains data on ...
0
votes
0answers
30 views

How to select the longest vector in a couple of parallel polylines?

I work with ArcGis 10.2. I need to find the longest vector in a couple of parallel vectors. They are extracted from an Intersect of Streets buffer and a flooding limit. So I have sometimes only one ...
1
vote
1answer
42 views

How to Select By Attributes on only Field with all its chars in Capital letters?

Need some assistance with this situation: I have a polygon feature class with a string Field. It has mixed values like: "PARIS" - "LISBON" - "london" - "luxemburg" - "Athens". In this example, I'd ...
2
votes
0answers
47 views

How to move points to another polygon based on attribute?

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 ...
-3
votes
1answer
46 views

Is there a function when using Select by attributes, to select only the continents' annotations?

Annotations beginning with character "C" refers to continents and I want to select only these annotations.
0
votes
0answers
51 views

select by attributes in modelbuilder while using iterate?

I have crated a model that iterates GPX-files from a folder and works through it and gives me a raster as output with pixel values after how many tracks passes through each pixel. This works the way ...
1
vote
1answer
52 views

Stream Trace to Select Attributes

I'm trying to work on a school project, but I only need streams up stream from a certain point. As you can see in the picture, I've run the stream trace tool upstream from a point i've created. I'm ...
0
votes
1answer
93 views

How can i use unicode characters in select by attribute?

I'm new to use python scripting for ArcGIS . I have unicode characters (arabic) in attribute table. I want to use these characteres in my script .when i use these characters in the script, the script ...
0
votes
2answers
310 views

QGIS select features from attribute table using the “LIKE” operator

I created an expression with the help of the GUI in the QGIS attribute table of a vector (shapefile) layer of Native American ("Indian") reservations in the USA state of New Mexico. "NAME" LIKE ...
-1
votes
4answers
357 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 ...
0
votes
1answer
76 views

problem with SelectLayerByAttribute management in script

hello my problem is that this tool works perfectly in IDLE or PyScripter programs, but if I use in the script in ArcGIS desktop this problem occurs: arcgisscripting.ExecuteError:ERROR 000582... why ...
1
vote
1answer
187 views

QGIS Advanced String Filter Expression returns too many results

"GNR" is a string column and I expect the filter expression "GNR"='.11' to only return the feature with the value '0.11'. Why are the other features with values of '.110'and '.1100' included? Is ...
1
vote
1answer
110 views

What is correct Where Clause when using variable and Select By Attribute tool within loop?

I have seen several similar posts related to this technique but I am still having issues. The following script is intended to select all points from one shapefile that are within the boundaries of a ...
0
votes
1answer
46 views

Using attributes of a polygon in one layer to identify polygons in another

So I'm in the process of developing a web application, I am using open source tools so qgis, postgis, play framework for the web app. And I have come across an interesting problem that I'm trying to ...
3
votes
1answer
84 views

Is it possible to save frequently used expressions in QGIS?

Is there any way to save frequently used expressions in the selection or field calculator dialogs? Obviously I can cut and paste them into a file where I might save them, but I mean within the context ...
1
vote
0answers
52 views

select remove layers not working second time

http://www.youtube.com/watch?v=qxVO0tFdiuA&feature i captured video. You can watch. Now i explain my problem. Firstly, when i create popup and in popup menu when i call function and select ...
3
votes
1answer
156 views

ArcMAP SQL Statement Iterate Feature Selection 'IN' 'BY' 'IS' - escape character

We have a problem when selecting Features from a Feature Class in ArcMAP 10.2 using the Iterate Feature Selection tool in Model builder Our dataset has a Attribute Field with two character codes like ...
2
votes
0answers
153 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
2answers
238 views

Why cant 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 ...
0
votes
1answer
52 views

How to subset some polygons from shapefile?

I have a shapefile of lakes with lots of polygons. The area I'm interested in is only big lakes. Is there any way to subset only the polygons I interested from the shapefile? How can I do it in ...
0
votes
2answers
210 views

What causes ExecuteError: ERROR 000358: Invalid expression Failed to execute (SelectLayerByAttribute) on shapefile? [duplicate]

My script runs perfectly for feature classes, but not shapefiles. It crashes at the point of selection, provided there is a query. gp.Workspace = "C:/someworkspace" fc = "featureclass.shp" query = ...
0
votes
1answer
124 views

Python problems with select by attributes and user input

I am attempting to create a tool where the user can input a census tract number within the city of Plano (there are 77 tracts) and it ultimately creates a map layout showing the population density. I ...
0
votes
1answer
57 views

Arcpy SelectLayerByAttribute for loop with “ADD_TO_SELECTION”

I am a little bit confused with the "ADD_TO_SELECTION" possibility. I process a point layer. First, the idea was to process the points with the different GBAUPS attribute separately. And it worked ...
1
vote
0answers
86 views

How to select and highlight feature by attribute

I have the below code which does a select by shape on my arc map how do I achieve this with attributes 1.The map has only one layer 2.There is a filter for the attributes on features Below is the ...
1
vote
3answers
1k views

Zoom to selected features with ArcObjects

I am trying to figure out what is the best way to set the active view extent to be able to view all the selected features on the Arc Map. 1.The Map has only one layer. 2.The features are filtered ...
0
votes
0answers
65 views

arcgisscripting - setValue error

I'm having difficulty isolating this problem - at the point I attempt to alter a record with update cursor, the script returns a 999999 error. I've tried running this script without ArcMap running in ...
1
vote
2answers
87 views

How to implement predefined attribute filters in an Openlayers web map? [closed]

I imagine this situation: I've got relatively big point layer and I want to split(filter) the points to predefined selections. Predefined selection would be based on the attribute(for example ...
2
votes
2answers
1k views

How to select multiple value in select by attributes in ArcGIS 10

Does anybody can help me with select multiple values from the attribute table? I try this command: "Classes"='14'AND'07' but doesn't work. Thank you.
5
votes
1answer
184 views

ogr2ogr selecting features by attributes

I am writing a shapefile after some processing; however, in the final step I need to do some selection by attributes from the the shapefile. I am using the command in a shell with the aim of using it ...
2
votes
2answers
94 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 ...
0
votes
0answers
136 views

Show live attribute when hover in a map

i'm still new in openlayers. i would like to show "location" attribute on right corner of the map when hover in map. my map consist of of many attributes and one of them is location. how can i ...
1
vote
1answer
211 views

Select by SQL in QGIS Python

In the GUI there is the Query Builder, but that does not seem to be easily available in Python. The processing (SEXTANTE) module has the qgis:selectbyattribute algorithm, but that only supports ...
5
votes
2answers
108 views

Select 90% matching attributes

I have a shapefile (.shp) of 180k roads with information of street name. I need to do a Dissolve on that road network to make only one feature per name. But I have a problem by doing that task ...
0
votes
2answers
79 views

Selecting a polygon within polygon where part of its boundary is the same. PostGIS

I would like to know how can I select a A_polygon within B_polygon, but part of the boundary of the A_polygon touch the B_polygon boundary. In Postgis 2.0, I tried few options but they didn´t work ...
3
votes
2answers
393 views

How to group and count attribute data?

I have a problem with group same data to count it. for example, i want to group same code to one and count them. i can do it when i use MapInfo (Pic 1) but i can't in QGIS. (Pic 2: i can classify ...
1
vote
1answer
393 views

Subquery a list in select layer by attribute management using python

I am new to python and having trouble with my script. I want only the records from the COMTRS field (of the pur_dbf_view) that match values from the ComtrsList to be selected; however, I am getting ...
2
votes
2answers
600 views

ArcMap 10.1 How to make mass (in bulk) update by attribute value

I have feature class with 70,000+ records (file geodatabase). I want to make in bulk update on an attribute where the value is NULL. Select by attribute shows that I have 5,000 records like that. ...
1
vote
1answer
150 views

OGR: How to best use GetFeature on a selection?

I think the following is very confusing sel_str = "ND_14 = '108'" l.SetAttributeFilter(sel_str) l.GetFeatureCount() >>> 1 In a for-loop this gives me for f in l: g = ...
1
vote
1answer
138 views

OGR: How to save layer from AttributeFilter to a shape filter?

I select a subset of features from my shape file like so: node_lyr = nodes.GetLayer() q_str = "%s = %i" % (field, value) node_lyr.SetAttributeFilter(q_str) What is the best way to make a shape file ...
0
votes
2answers
235 views

Arcpy SelectLayerByAttribute_management where_clause with LIKE not returning like values

I am selecting 2 intersections from a shape file using info from a File Geodatabase Table. The values are very similar as shown in example at the bottom. I am using a LIKE in the statement but it is ...
0
votes
0answers
26 views

How to select areas from a target layer which do not intersect source layer? [duplicate]

I have two different layers, one is county boundary and another one is soil map. My question is I would like to select only those areas which are outside the county boundary. Using "Select by ...
2
votes
1answer
296 views

Trouble formatting SQL expression for where clause in “Search layer by attribute” arcpy function

I am trying to pass a variable into a where clause in the "Search Layer by Attribute" arcpy function. I cannot seem to figure out the correct format for the SQL expression so that the function reads ...
0
votes
1answer
87 views

ogr SetAttributeFilter uppercase?

How do I use the ogr SetAttributeFilter with uppercases? Code example: lyr = shp_obj.GetLayer() sel_str = "%s = '%s'" % (field, value) lyr.SetAttributeFilter(sel_str) Can I just do: sel_str = ...
1
vote
1answer
435 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 ...
0
votes
2answers
291 views

How to iterate through only select attributes of a single field using ModelBuilder in ArcMap 10.1

The feature class that I am iterating with ModelBuilder is a polygon FC called "Alignment" in my model. My current solution to iterating through only certain attributes of a single field does not seem ...
1
vote
2answers
119 views

how to add a raw input to a SQL string?

I have this py script for selecting one point. # Within selected features, select only those points of a chosen value arcpy.SelectLayerByAttribute_management("Stations", "NEW_SELECTION", ' "OID" = ...