Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to simply process a layer by writing a tool script in a toolbox without having to connect any database, so I think I may have to set up a workspace environment in ArcMap, but I'm not sure if I need to do anything else.

Essentially I want to find a Python version of the ArcObjects IWorkspace.ExecuteSQL method.

share|improve this question
i'm not that clear what you're asking for, but... have you reviewed the doc for ArcSDESQLExecute ? Edit: also see GP Considerations for working with SDE – gotchula Dec 31 '12 at 21:20
up vote 1 down vote accepted

For file geodatabases, I do not think this is possible through arcpy, but it is using GDAL/OGR: ogr2ogr / GDAL remove features in FileGDB while in use by ArcGIS Server map service

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.