Select to view content in your preferred language

Query Layer

862
1
03-09-2011 12:03 PM
KeithSandell
Regular Contributor
At 10, ArcMap, under File > Add Data > Add Query Layer, allows the user the interact directly with the underlying RDMS, i.e. SQL 2008 Spatial.

This function DOES allow for spatial queries, i.e. STIntersects, etc. against the RDMS.

Has anyone found a way to access the properties, methods, etc. of this function in Python?

Want to send spatial queries to SQL through geoprocessing service that is consumed in Javascript API web map app.

Thanks
Tags (2)
0 Kudos
1 Reply
ChrisSnyder
Honored Contributor
Try the MakeQueryTable tool in ArcToolbox. The 'Expression' parameter is where you would put all the SQL. I haven't tested it using any SQL spatial stuff though - just tabular stuff I use to make pseudo spatial views. Be sure to return the Shape field in the query, else you only get a table view back (and not a feature layer).
0 Kudos