Questions tagged [definition-query]

A request that examines feature or tabular attributes based on user-selected criteria and displays only those features or records that satisfy the criteria.

24 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
3
votes
0answers
200 views

Current date in query builder Qgis

I'm trying to put a query on a vectorlayer with the current date. The following code works, but I want the current date to be dynamic: cast ("Starttijdstip" as character) < '2018/03/01' AND '...
2
votes
0answers
61 views

Create filter expression by selected elements?

Is it possible to automatically create a filter expression for the Query Builder by selected elements?
2
votes
1answer
194 views

Using min-max functions in definition queries of feature services

Using a feature service from ArcGIS Online, I would like to display a record wherein one of its attributes is the max of the entire records, but is unable to do so. If I am using a Feature Class from ...
2
votes
0answers
631 views

Layer Definition Query - Subqueries

Background: I want to track the movement of icebergs in ArcGIS. In my FileGeodatabase I have a single Iceberg layer. What I have thought of is to create an ID field for each object; each ArcGIS ...
1
vote
0answers
16 views

Linking Feature Classes between Two Different Map Frames so that Definition Queries in one Frame Apply to Another Frame

In ArcGIS Pro 2.4.1, would like to determine whether it is possible to link two identical feature classes, where feature class 1-1 is in map frame 1-1 and feature class 1-2 is in map frame 1-2. The ...
1
vote
0answers
33 views

Setting up definition query to run through ModelBuilder on ArcMap?

I am trying to make a model that will symbolize data quickly, but wanted to see if a model could perform a definition query or multiple definition queries on a large data set. If this is possible, ...
1
vote
0answers
31 views

setFilterExpression not giving results because of space?

I am trying to select data based on QgsVectorLayer() getting it's features from layer.getFeatures().next() method. When I pass expression in that using QgsFeatureRequest().setFilterExpression(...
1
vote
0answers
389 views

Definition Query with GETDATE()

The expression FieldData1 <= GETDATE () AND FieldData2 >= GETDATE () works well, but if FieldData1 = FieldData2 does not work. ArcGIS 10.3.1 Desktop and SQL Server 2008. Any suggestions?
1
vote
0answers
93 views

if column name = this, then search for a row >0 and change symbol, in QGIS

Excuse me as I am new to GIS. I am using QGIS to do two things. Firstly, from a csv master file, I have plotted points on a map based on their geo-reference and graduated their colour based on the ...
1
vote
0answers
412 views

Definition query to extract last updated record

I am struggling to build a definition query using ArcGIS to select last updated record in relation to unique CADID (core data example below). CADID is unique, updates recorded additional record in ...
1
vote
0answers
220 views

“Definition Query on a versioned Geodatabase”

I would like to implement Specific views to the SDE users, based on Definition Queries of common attributes , like Date created > = October 1. But on first look, the definition queries are for "...
1
vote
0answers
358 views

Can ModelBuilder be used to export different versions of the same mxd with various constraints?

I am currently trying to use modelbuilder to go through each row in an attribute table, select the streets that intersect the polygon (which is the row in the attribute table), zoom to the selected ...
1
vote
2answers
393 views

How to apply a layer definition with a spatial query to a Dynamic layer?

Using the ArcGIS Server JavaScript API, it's possible to specify an attribute query in the form of a layerDefinition against a Dynamic layer. For example, the following query will restrict the layer ...
0
votes
1answer
46 views

Definition Queries for most recent date in ArcGIS Pro

I have a feature class containing sample results for locations that includes thousands of records. Many of these are overlapping and have the same location ID. I need to label each sample based on the ...
0
votes
0answers
98 views

Query returning multiple vehicle_ids when it should only return the top 1

Using ArcGIS Desktop 10.5.1 I have a point featureclass in an Microsoft SQL Server 2012 Enterprise Geodatabase (ArcGIS Server 10.5) that holds MDS (mobility ride share scooter) data. The feature ...
0
votes
0answers
38 views

How can I create a layer for each unique field item in a shapefile using Arcpy

#Introduction and imports import arcpy, string from arcpy import env #User Inputs: layer, field name, output workspace (optional) strTargetLayer = arcpy.GetParameterAsText(0) strFieldName = arcpy....
0
votes
0answers
34 views

Dynamic SQL Expression Parameter in Model Builder tool (Arcmap 10.3)

I have a working model in Arcmap 10.3 that creates a feature class data from CSV file, queries the data according to a SQL Expression, and then conducts many spatial joins. The model works as ...
0
votes
0answers
40 views

Accessing Feature Service via ArcGIS REST API to Customize App in Operations Dashboard?

Beginner here Just learned how to construct url to access the feature services needed to build the customized app I envision in Operations Dashboard, but struggling to find a tutorial/resources ...
0
votes
0answers
164 views

Creating script tool for definition query using user input

I have a map document with about 10 layers that I would like to create a query definition script tool to use that takes a user input as a parameter and then executes the tool. The script looks like ...
0
votes
0answers
126 views

Customizing complex layout with data driven page?

Main Conditions: It should be in one MXD document. What i have: 1 line feature (with definition queries), 1 polygon feature (with definition queries) this is one as example in fact number of layers ...
0
votes
0answers
390 views

sub-querying 3 tables in definition query without join

I'm trying to select record from Table 1 which has more than one kind of 'Type' in Table 3. There is no common ID between Table 1 and Table 3. But Table 2 has LID that's common to LID in Table 1. ...
-1
votes
1answer
320 views

Updating Page Definition Queries with Python and data driven pages?

I have several annotation features that each have a tileID field. I would like to be able to enable the page definition query and select the correct Page Name Field to match the tileID field in all of ...
-1
votes
1answer
66 views

Leaving cities with less than X number of observation in ArcGIS for Desktop?

I would like to generate some quintile maps based on the averaged sentiment score in each city in the US. However, not all the city has the same number of data point. How can I tell ArcGIS to show ...
-1
votes
1answer
45 views

Will replacing workspace path affect definition queries in Maps or Layer Files?

I am doing a cleaning up project for some of my data. This requires a data structure. That means I will have to replace the workspace path in the MXDS. The old structure of the data will be ...