A command used to retrieve information from a database

learn more… | top users | synonyms

2
votes
1answer
97 views

Model or Code to query all feature classes in geodatabase by selecting by attribute

I have a geodatabase that has 60+ feature classes that each contain records for 60+ locations. I need to export all records from each feature class for a specific location. In each FC there is a ...
0
votes
1answer
269 views

OpenLayers CQL filter gets info about NOT VISIBLE features

I have a WMS layer and a control WMSGetFeatureInfo. If I apply a CQL Filter to the layer and I redraw it, the WMSGetFeatureInfo control continue querying also NOT VISIBLE features. Why in your ...
3
votes
2answers
227 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
125 views

Mapinfo SQL Query for compare for edited data in tables

I have a table that contain several columns, each has their own data. then, someone have made some change in the data (just a little one data editing). how do i know later what data have been ...
1
vote
0answers
60 views

PostGis search query on hstore tags

I am writing a search client, to query postgis db. The search query will be, SELECT tags->'name' AS name,ST_Transform(way,4326) AS pt_lonlattext FROM planet_osm_point WHERE lower(tags->'name') ...
1
vote
3answers
110 views

How to search for several different features in the attribute table?

I guess my problem is a quite simple one, but the query builder and I have our difficulties, so maybe someone can help me. I have a long attribute table in QGIS and am trying to extract about 200 ...
2
votes
2answers
88 views

Determining closest representation of polygon as collection of points+radii

Have a bit of a tough question, which I realize there may not be an easy solution to. Figured what better place to ask. I'm attempting to transform a polygon into a series of arbitrary points with ...
1
vote
2answers
84 views

Reverse querying

Is it possible to run a reverse query? In other words, I have a master shapefile and a derived shapefile containing data extracted from the master file, but don't know what criteria the extraction ...
1
vote
1answer
68 views

Counting and sum by two layers

I´ve got to layers, both polygons. Layer 1 consists of propertiers, where ID is individually names. Layer 2 consists of lakes. The query I want is: Total count of squaremeters of lakes for each ...
1
vote
2answers
361 views

spatial query st_contains postgis

This seems too simple to be asking this but I am really new to postgis/postgres have been going around in circles with this. I am performing a really simple spatial query where I would like to make a ...
2
votes
2answers
251 views

Merge lines with the same 'name' attribute on QGIS?

I have a shapefile with a few thousand lines, each is a street segment. I'd like to merge all features with the same 'streetName' attribute into a single attribute. I only really care about the name ...
3
votes
2answers
237 views

Why does ArcGIS Server not return data when querying joined fields?

I've been trying to help troubleshoot an issue that is very strange, and I think we've boiled it down to an issue with ArcGIS Server. We have a map service that shows up in the services directory as: ...
1
vote
1answer
23 views

Why do I suddenly get 'ERROR' as elements in my attribute table after doing a query in QGIS?

I was looking at an .osm file in QGIS using the OSM plugin; I was specifically looking at a country's lines layer. When I checked the attribute table just after opening the .osm, everything looked ...
2
votes
1answer
186 views

How can you tell if a RDBMS is an ArcSDE Geodatabase?

I want to know if there is any way I can query the RDBMS to determine whether it is an ArcSDE Geodatabase, or if I have to do it through ArcObjects. I am wondering if it would be enough to check if ...
0
votes
1answer
82 views

Spatial query without spatial database module

I have the following scenario: Oracle database without the space module. Application in JEE2 with the following architecture: -- Entity -- Persistence (DAO / JPA + JDBC) -- Business (BC) -- Vision ...
1
vote
2answers
184 views

How to speed up spatialite-query using spatialindex?

I have got 2 tables, one of type LineLayer called strlayer, the other one is a PolygonLayer called blayer. The LineLayer contains two rows called fromBland and toBland that should be filled with an ...
1
vote
0answers
125 views

ArcObjects: How to Speedup Spatial Query to Feature Layer?

I have ROAD (POLYLINE) Shape File with more than 400,000 Records. I am working on a code which goes like this: Loop through all Feature of the Shape File Take First Feature Find the LAST VERTEX of ...
0
votes
2answers
122 views

oracle search against intersect of a region that covers the whole world doesnt find any records

I am new to Oracle Spatial, I am trying to implement a service that will take coordinates from a map, and search our database to find any geometries that intersect with that map view. I works fine for ...
0
votes
0answers
34 views

SQL Query Remove Multiple Attributes

I'd like to query a street layer by the ownership of the street (State County etc). I know I can do "Road_Auth" <> 'IL' or "Road_Auth" <> 'Kane' and so on. This question Select by ...
0
votes
1answer
296 views

A couple GeoExplorer questions

I just started working with the OpenGeo Suite. I'd really like to use it for a County web map, but have a couple questions... 1) Is there a way to add a lat/lon or other X/Y location to the URL and ...
2
votes
2answers
164 views

Select by Attributes - If string has a letter

I'm running ArcMap 10.1. I'm using a File Geodatabase. I have a string coordinate field that I want to clean and some records have letters in it (mostly 'N' or 'E' or 'n' or 'e' e.g. '6213210N' or ...
1
vote
1answer
166 views

IQueryFilter where Clause quering two feature class at a time

I need to query two feature class at the same time using IQueryFIlter. For eg - FeatureClass -- A has field OBJECTID FeatureClass -- B has field OBJECTID what i am tring to do is -- IQueryFilter ...
1
vote
2answers
56 views

Find the majority area within another area

I have a survey grid overlaid unto several administrative areas. Both are polygon features and I have performed a union on both features in order to determine the areal contribution of the segments ...
0
votes
1answer
134 views

Circles created by points inside bounding box query - PostGIS

The table that i want to perform this query has 3 columns: id, the_geom and seen_count. The query i've been using to get points inside a bounding box is as follows: SELECT id, ST_AsGeoJSON(the_geom) ...
1
vote
2answers
291 views

ST_DWithin uses Geometry or Geography type

assuming I use the following query to match the locations to a poi within 10km distance: SELECT poi.poi_id, h.loc_id, (ST_Distance(poi.geom,h.geom)*111.111) as distanceinkm FROM iut_poi_transl AS ...
0
votes
3answers
92 views

Comparing polygon attributes that share the same parcel?

I'm new to ArcGIS, or at least anything beyond the basics, especially ArcToolBox. so the answer might be extremely simple. Basically I have one layer of building footprints, and another layer of ...
0
votes
1answer
65 views

How to select all cities in Germany from city and country layer?

I have 2 layers: layer_1: countries of europe, layer_2: cities of europe I want to create (and then save) a layer_3 which would be all the cities of Germany. Is there any good tutorial of how can i ...
1
vote
1answer
345 views

Why isn't my select by attributes query working?

I'm running ArcMap 10.1. I have a point feature class joined to a table and am trying to query a field. If I do [field] = 'TEST', it selects all the fields. But if I do [field] LIKE 'TES%', it ...
0
votes
0answers
62 views

ArcGIS server 10 web adf query attributes task results sorting

I'm fairly new to web mapping and my company uses ArcGIS server 10 web ADF. I've used 'query attribute' task and given the list of data to select from. Now I was asked if I could sort those results ...
2
votes
1answer
242 views

Help building SQL query to get a list of streets of a city

From two layers in PostGIS (osm_places and osm_roads), I would need to have the roads belonging to a certain city. It would be fair enough to get the street names of all streets in a radius of X ...
2
votes
3answers
261 views

How can I export or query all hospitals from Open Street Map?

I'd like to extract all the hospital locations in the US from Open Street Map as a reference for my geocoding project. I know how to get all the OSM data for a small area with the QGIS plugin but not ...
3
votes
0answers
214 views

Select features within a country or bounding box effectively using PostGIS

I imported the planet OSM file into a PostgreSQL 9.2/PostGIS 1.5 server using osm2pgsql. I now want to select certain map features which lie within the bounding box formed by a countries borders, e.g. ...
1
vote
1answer
62 views

For each polygon, return yes/no value if it intersects another layer

I have a polygon grid overlaying several other polygon vectors. I wish to visit each polygon in the grid and ask yes/no if each of these layers fall within the grid cell or not. I can do this easily ...
0
votes
2answers
169 views

PostGIS, distance between two users

I have a simple table (location_test) with three column (name, geom , jid). geom is a geometry column with SRID 27700. I set the user's geometry position with: UPDATE location_test SET geom = ...
2
votes
2answers
451 views

Built a query for polygon Shapefile in R

I use the package maptools to read in Shapefiles in R. I would like to know if there is a function that can built up a query/subset to select only some Polygons based on a specific attribute in the ...
3
votes
2answers
104 views

How to query for a specific point, within a specific polygon?

I have a shapefile points layer, with each point representing either Marginal, suboptimal, or optimal conditions. I want to find only the marginal points within a specific polygon from my catchments ...
2
votes
1answer
166 views

Merge attribute data using spatial query in QGIS

I have 2 vector layers that I wish to correlate attributes - a shape file containing boundary polygons and a shape file containing point locations. I'm using the vector>spatial query tool to generate ...
3
votes
1answer
120 views

Filter contour lines in QGIS

I have a shapefile of contour lines, with an ALTITUDE attribute with the height ASL in metres. The source data is in 0.5m intervals, but I'd like to filter it down so I get contour lines at (for eg.) ...
1
vote
2answers
255 views

What are the options for working around the max number of records returned for a query task on ArcGIS Server 9.3.1?

I'm trying to return polygon features that intersect a larger polygon which defines my area of interest. It is working in some cases, but when the area of interest gets large (7000 intersecting ...
1
vote
1answer
423 views

Querytask/query - executed select

Is there a way to get to the query condition, which is executed under the querytask ? I have an example, which is actually a copy of this ArcGIS example ...
1
vote
1answer
170 views

How can I change SQL query through a layer of an action (python)?

I have three layers from three diferent database tables. When I click in other layer I want to change (with an action) the query of that three layers. How can I do that? Thank you
4
votes
3answers
352 views

How to create Where Clause from user input via Python list?

I am trying to perform a query based on values in a Python list. The where clause will then be used in an Update Cursor, so that the rows NOT equal to the values in the list will be deleted. This is ...
2
votes
1answer
301 views

Reading OGC geometry data from SQL server using R

I would like to write a script in R that creates a map using OGC geometry data that is stored on a Microsoft SQL server. Is there a way to read OGC geometry data using a query passed from R? Maybe ...
0
votes
1answer
104 views

In QGIS can I show just the lines in a Postgis query? How can I do that?

I have three tables in Postgresql, each table with one layer of lines. I want to show the path of an initial line to another final. Is it possible executing a SQL query? Thanks My three tables are ...
4
votes
1answer
517 views

How to Find points in a Kilometre radius

I am new to PostGIS and GeoData. I need to find where the lightning has stroke by a period of time and kilometre radius based on a given location. I have given lon/lat and my table is: latitude ...
1
vote
1answer
168 views

How to get the nearest line to a feature?

I have features on map, and i want to get the nearest poly-line to each one. How to write spatial query to get the nearest one. I tried to use ISpatialFilter but i couldn't reach anything.
4
votes
1answer
404 views

How to speed up an st_intersects() query?

I have a "huge" spatial database: 72GB, 200 millions documents with geometries (points) I have a GIST index on the geometries the database: CREATE TABLE resources ( id bigint NOT NULL, accuracy ...
2
votes
2answers
260 views

Selecting lines occupying identical positions in MapInfo or QGIS

I have two shapefiles from a client, one is their entire network (complete with unique IDs) and another a selection I need. However the selection file does not have unique IDs but the entire one does. ...
1
vote
0answers
363 views

ArcGIS API Javascript - FeatureLayer from json: problem with queries and popup

Hello everybody I've tried this code proposed by Derek Swingley in JSFIDDLE: JSFIDDLE-FeatureLayer from JSON Everything "seems" to work fine, but not always. If you go down to the closer scale (level ...
0
votes
1answer
41 views

Isolate And Save Raster Features From Existing Multivalue Raster Map

I have Cyprus Corine map with 44 different types of land use. I want to run a raster calculator query or any other way to isolate the areas with codes 10 to 22 and 26 to 34, all other values 1 to 44 ...