RE: [okgis] Queries

Chronological Thread 
  • From: "McGaugh, Miriam J." <>
  • To:, "GIS Users Forum" <>
  • Subject: RE: [okgis] Queries
  • Date: Fri, 19 Dec 2008 10:39:53 -0600

You could also use model builder to set up some stored processes and set the layer and specific query options as parameters to be entered at the time of run.  Those models should be able to be served up to the web environment without much problem.

Miriam McGaugh, M.S.
Community Development Service
Oklahoma State Department of Health
1000 NE 10th St, room 508
Oklahoma City, OK 73117
Direct Line: 405-271-9444 x56466
CDS Office: 405-271-6127
Cell Phone: 405-208-1043

From: Todd Fagin []
Sent: Friday, December 19, 2008 10:30 AM
To:; 'GIS Users Forum'; 'Oklahoma GIS Community'
Subject: RE: [okgis] Queries



By example, say you have a school district layer and a wells layer and you want to find all wells that are within the Mid-Del school district.  You actually have to do two queries in ArcMap:


  1. Select by Attribute:  in your select by attribute query builder, your Where statement will look something like: NAME = ‘Mid-Del’ (of course, this is all dictated by your actual data so your field names and values may be different
  2. Once the appropriate school district is selected, you do a Select by Location query.  In this query, you will select features from your well layer that intersect (or are completely within or a number of different spatial options) the features in your school district layer.  However, be sure that the “Use selected features” option is selected because you only want to select those that are inside Mid-Del, for instance.


Your other queries will likely take similar form. Depending on the spatial relationship you’re trying to find and other criteria.  You ask, for instance, where your pipelines cross.  Do you mean where the pipelines cross other pipelines?  If so, are the pipelines all in one layer or different layers?  If different layers, you can simply do a select by location/intersect.  You can also do a spatial query where a layer intersects itself.  However, in order to do this in ArcMap, at least one feature must be selected.  So, if you want to know all pipelines that intersect pipeline A, you would do a select by attribute query to first find all pipeline features meeting the criteria of being pipeline a, then you do a select by location query in which you select features from pipeline that intersect the selected features in pipeline. 


Finally, if you are wanting to know where your pipelines cross a different layer (e.g. something from StreetMap USA), a Select by Location, Intersect should work.


Make sense?


Todd Fagin


Coordinate Solutions, Inc.

2804 NW 18th St.

Oklahoma City, OK 73107

405.740.4324 (voice)

904.471.5548 (fax)




From: K C Spain []
Sent: Friday, December 19, 2008 9:45 AM
To: GIS Users Forum; Oklahoma GIS Community
Subject: [okgis] Queries



Hello and Happy Holidays.


I’m sure as most of you know, I am still quite an amateur at this. I haven’t had to deal with queries until now and I feel these questions are going to be difficult for me to put into the right words, so bear with me. I have learned recently that my ‘higher-ups’ wish to implement some querying in my GIS. For example, Wells (points) within ‘specific’ school zones (polygons). The school zones are in one layer but are identified with unique values, ‘name’, as are the wells. Also, I will be needing to query where my pipelines cross, in Streetmap USA, ‘Streets and Highways’, ‘roads’, ‘railroads’, ‘water’ etc.. And does anyone know if and how these queries would carry over to my web application? I have looked at the Query Builder and I am not seeing exactly what I’m looking for. If anyone could shed some light on the subject for me or point me in the right direction, I would greatly appreciate it.





K.C. Spain

Tech. Asst.

Stephens Production Co.

623 Garrison Ave., P.O. Box 2407

Fort Smith, AR.   72902

ph.  (479) 783-4191 ext.206

fax  (479) 424-1344 


This e-mail (and attachments if any) is intended for the use of the individual or entity to whom it is addressed, and may contain information that is priviledged, confidential, and exempt from disclosure under applicable law.  If the reader of this e-mail is not the intended recipient, you are hereby notified that any dissemination, disclosure, copying, distributing, or the taking of any action in reliance on the contents of this communication is strictly prohibited.  If you have received this communication in error, please notify the sender immediately by return e-mail and destroy all copies of the e-mail (and attachments if any).





This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Archive powered by MHonArc 2.6.16.