A command used to retrieve information from a database

learn more… | top users | synonyms

0
votes
1answer
27 views

How to query all layers in ArcMap and get access to them by name or index?

I have next issue: I have ArcMap with tons of layers. Some of these layers may contain another layers with data (aka Composite layers) or they don't. The depth of composite layers in unknown. I need ...
2
votes
0answers
32 views

ArcGIS API for Silverlight : query that displays layer attributes in a dataGrid

I'm working with ArcGIS API for Silverlight to build a webmapping application and I'm trying to display my attributes in a datagrid. I made a try by using this code : void ...
3
votes
0answers
39 views

Postgis database query optimisation

I have a set of rasters in DTED format which I load into postgis database using raster2pgsql command line tool. Each of rasters is simply stored in a row and described by rid and a value of raster ...
1
vote
1answer
17 views

Using query in a while loop causing android application to freeze

I am having some troubles with the while loop + query. What I'm trying to do is track the user location (using onlocationChanged) and keep querying a FeatureLayer until the query returns a result and ...
1
vote
0answers
7 views

Geoexplorer - How to open query panel in a bigger window?

The query panel in Geoexplorer (displayed in lower left corner) is so narrow, that entering data in it may be cumbersome. How can i configure Geoexplorer to open this panel in a bigger window and ...
3
votes
1answer
46 views

How to use ST_HausdorffDistance (PostGIS, QGIS)

I want to snap the GPX-track to the road network as the image below shows. I found out, that "Hausdorff Distance" is exactly what I need and that it is usable with PostGIS. But unfortunately I have no ...
0
votes
0answers
15 views

2.4.0-Chugiak PostgreSQL layer subset causes DB error

I have succesfully connected to pgsql layer. I got an error after trying to define feature subset in query builder. Can anybody help with this error? An error occurred when executing the query. ...
2
votes
0answers
18 views

Querying a shapefile and returning values?

I have a lot of experience making maps in ArcMap. I don't have much experience programming or working with APIs. Here's the (simple) problem: I create a shapefile of a region and then load the ...
0
votes
1answer
20 views

GeoTools exception: failed to connect to EPSG database

I downloaded the GeoTools 11.2 binary and am attempting to get it to run in my Netbeans java application. I tried to run this part of code: ... SimpleFeatureSource source = ...
3
votes
2answers
72 views

How can I extract all distinct values from a PostGIS Raster?

I am working with an integer raster in PostGIS 2.1 and I would like to extract all distinct values in that raster. I was hoping to be able to do something along the lines of the following query, but I ...
1
vote
0answers
53 views

How to count the number of coordinates within x meters grouping by distinct ids?

I have a table "items" of about 1 million rows and 40.000 distinct ids like the following: idx | id | point | lat | lon | the_geom 1 | 1 | 76 | 51.463388 | -0.16869856 | 0101000020E... 2 | 1 | 53 | ...
0
votes
0answers
62 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 ...
0
votes
0answers
41 views

Removing highlighting when selecting feature in Arcmap

Whenever I select a feature in an attribute table it gets highlighted which prevents me from seeing the symbology of that feature. I tried choosing No Color in the appearance option, but that results ...
0
votes
1answer
63 views

Summarizing at Modelbuilder

I like to summarize of the ID-Field with the ModelBulider because in the end I have to build a tool. The problem I have is that the field “GRIDCODE” should get in the new table comma separate. So that ...
0
votes
1answer
43 views

How to run spatial query get fields value of 2 layers?

Last month I ask a question "vb.net arcobjects spatial query get fields value of desired layer only", url vb.net arcobjects spatial query get fields value of desired layer only. Now there is some ...
0
votes
1answer
60 views

Create spatial view that references multiple databases

Based on this link, it sounds like I can create a view from separate spatial databases. Cross-database queries are permitted and ArcSDE views can reference data from multiple databases provided ...
2
votes
2answers
43 views

Parse Field to Select Records

I wish to select records based on the NRN attribute in my dataset : "NRN" IN ('1','2','23','31') Some records have multiple values in the NRN field separated by the underscore character. For ...
0
votes
0answers
24 views

MySQL Select rows where line strings are within a bounding box

I have a MySQL DB with some spatial data stored in a table after being input via ogr2ogr from a shapefile. The structure is similar to the following: OGR_FID int SHAPE geometry (all line ...
5
votes
2answers
178 views

Selecting maximum Value based on other field using ArcMap?

I have problems with a SQL query. The table looks like this, it is a point feature class both in postgres and file geodatabase, I am working in ArcMap. name: elev_p HEIGHT AREAid 100 1 200 1 ...
1
vote
1answer
37 views

Spatial queries to find co-occurrences of POIs

Given a POI database containing different types of points, e.g. hospital and pharmacy, how can I select the locations where a hospital and a pharmacy are closer than a certain threshold (e.g. 1000m)? ...
3
votes
4answers
126 views

Label using VBscript in ArcMap - multiple IF statements?

I have 4 fields that hold number values. I only want a label returned if the field <>0. For instance, if col1<>0, then label = col1 AND if col2 <>0 then label = col2, etc. So, I want all ...
1
vote
1answer
45 views

QGIS Filters and Queries

In QGIS is there a way to filter a layer using the Query Builder to show all values which include a particular phrase. For example I have a list of organisations and I want to filter all those which ...
0
votes
2answers
34 views

OSM, Query for POIs in a building

How can I construct a query (for example for Overpass) for getting all buildings where inside the building is a node (for example a shop)? L.
1
vote
2answers
62 views

Save Multiple Selection from Attribute Table

I am working with a shapefile that has all the address points for a municipality - it has over 500,000 features. I would like to search the attribute table for specific addresses and save those ...
1
vote
1answer
31 views

Setting the Geometry with sql query

I am trying to merge data from a U.S. states shapefile with data on each state. I used this SQL query which is supposed to work: SELECT * FROM child_poverty_by_state UPDATE child_poverty_by_state ...
0
votes
1answer
44 views

Querying Arcgis file geodatabase from sql

I need to compare data in a sql db with data stored in an arcgis file geodatabase. I'm not interested in the spatial attributes, only the added text attributes. What's the easiest way to do this? I ...
5
votes
1answer
89 views

Is it possible to use comments in QGIS Query Builder?

I am trying different queries in the Query Builder. Is there a way to comment the query? I tried with /* */ # -- without success : An error occurred when executing the query. The data ...
1
vote
2answers
64 views

Python query to find records with more than one alpha character in a field

Using ArcGIS Desktop 10.2. I have a field in a table of several thousand records. The field is made up of alphanumeric characters. I'd like to perform two queries using python on this field: ...
0
votes
1answer
56 views

Do ArcGIS Online feature services support a DISTINCT or returnOnlyUniqueValues option?

ArcGIS Server REST API has: returnDistinctValues Description: If true, then returns distinct values based on the fields specified in outFields. This parameter applies only if the ...
2
votes
1answer
79 views

How to extend a straight line in postgis?

I have a postgis table of simple linestrings, each one is a straight line with just two points. I want to select every linestring, but extended from both sides by 1 meter. So i have lines, that are ...
0
votes
1answer
52 views

Get CartoDB query by distance to work

Has anyone tried this tutorial: Query by distance ? This is a copy of the final code which they use for the map: <html> <head> <link rel="stylesheet" ...
2
votes
1answer
31 views

How do you create a query that will result with the adjacent parcels?

I have a shapefile with parcel data, and I am trying to create a query that will render a list or something similar that will list adjacent parcels to a specific parcel. I want to be able to select ...
0
votes
0answers
32 views

Query's “Get Unique Values” includes case variants that don't exist in attribute table

I ran a query on an ArcSDE 10.2 Feature Class to find features that do not follow our office's standard of being in uppercase. The "Get Unique Values" seems to return values that do not exist in the ...
0
votes
1answer
27 views

How to export query result on raster table in PostGIS

I did success query on a raster table in postGIS(raster data clipped by a vector polygon), now I want to view the query result in QGIS. But how to export the query result to another table. In vector ...
0
votes
3answers
83 views

postgis insert query to store geometry and other data

I'm using Postgis functions st_dump and st_split to split a polygon based on line. Now, after splitting; output geometry stores in a database table as well. Here is the query: insert into aoo(geom) ...
0
votes
1answer
37 views

PostGIS Group By Error [closed]

I am performing a pretty simple query in PostGIS 2.1.1 from within QGIS 2.2 for Windows (using the DB Manager plugin). I have a table with many columns and I am trying to perform a Group By function. ...
0
votes
0answers
42 views

Join Standalone Tables from ArcGIS Server in Javascript API

I am trying to find a way to execute the equivalent of the following query with the ArcGIS JavaScript API (I made field and table names generic): SELECT a.field1, a.field2 FROM table1 a, table2 b ...
2
votes
2answers
64 views

How to download only selected attributes using Overpass turbo?

does anyone know of a query to download select attributes using Overpass turbo? I am trying to download very granular road dataset for an entire country, but I only want a few columns. Thanks!
0
votes
0answers
32 views

The difference when querying raster and vector

Hi everyone I have two queries have the same meaning but different results. Why is there a difference?. Queries are true? query 1: query 2:
0
votes
1answer
74 views

Extract address data / Query point in administrative boundary

I try to create a DB in postgreSQL with all the postal adress data for a specific country. Actually I have this table full of data: id integer NOT NULL DEFAULT nextval('plz_id_seq'::regclass), ...
0
votes
0answers
47 views

pgrouting pgr_drivingdistance() query gives inconsistent results

So I have been working on a query(with the help of other stackexchangers :)) to get the edges in an isochrone from a particular point and then update the count_events field of those edges by some ...
0
votes
2answers
66 views

Keep receiving query error in Flex Viewer for Search Widget in ArcGIS Server

I am not sure what is going wrong, but I keep receiving this query error http://i.imgur.com/XXSpEpH.png Here are the settings for the search widget <?xml version="1.0" ?> ...
0
votes
1answer
235 views

SQL Geometry Query similar to Select by Centroid

Does anyone know if it's possible to query SQL geometry by something like 'centroid of polygon'...similar to ArcMap's select by location? I'm using SQL Server 2008 R2 as the DBMS. I have two polygon ...
0
votes
0answers
86 views

Clipping multiple layers in QGIS 2.2

I have huge amounts of data (multiple country-wide shapefiles) which i have to work with constantly. But working on separate cases i only need a fraction of that data (region, city etc.) Loading the ...
0
votes
1answer
159 views

How to write to Sql server from MapBasic and insert rows

I have created a table in Sql server 2014 with the columns: Id (int), Geom (geometry), RouteId (int), Desc (varchar(MAX)) I have succeeded in making the table mappable through MapInfo I have checked ...
0
votes
0answers
137 views

Java script vehicle tracking application

I am using ArcGIS and Server to build n application to track vehicles via tablet GPS in the vehicles. My original plan was to use a feature class to store point location and then display the most ...
3
votes
1answer
351 views

Problem PostGIS Spatial Query ST_Contains ST_Disjoint ST_Intersects

I'm working on a project with two different tables inside a database. One contains points in a column geometry(Point,4326) type and the second one has a column geometry(MultiPolygon,4326). Now I would ...
1
vote
1answer
160 views

query / filter on attribute tables with external tables joined

i tried to do some queries on joiend table fields ... i've got/found some answers concerning version 1.8 - which result in "use select + export to create a combined dataset" so i just did some tests ...
1
vote
2answers
209 views

Sql Query for percent of buffer filled with objects

Hi I am trying to write a query to find the percentage of a buffer polygon (Called 250_Buffer) that is filled with or contains other polygons in another layer (Called Development) any help that you ...
14
votes
1answer
356 views

How to query OSM for all beaches facing west? - QGIS preferred

I want to identify all beaches on this planet (or a given subset of it) that are facing westwards (+/- 20-30 degrees). My idea is to use OSM as the data source. Extracting all polygons that have the ...