I have a query layer directly running from ORACLE database in a MXD. I want to clip this layer with a layer being created in another MXD in a Python based tool. My question is to do this clip analysis, do I have to make a layer of this query layer locally or I can clip it directly from the query layer? I have success doing it with MakeFeatureLayer_management but then creating a layer of 6-7 million records every time this tool runs does not appear efficient and fails the whole purpose of creating query layer. SDE was never implemented for this project and setup was done before I joined the project. Alternatively I tried to run the model in query layer MXD but it will work stand alone and results in error with Python.

closed as off-topic by PolyGeo Aug 16 '16 at 0:55

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions seeking help to debug/write/improve code must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it in the question itself. Providing a clear problem statement and evidence of a code attempt will help others to help you. See: How to create a Minimal, Complete, and Verifiable example." – PolyGeo
If this question can be reworded to fit the rules in the help center, please edit the question.

  • also, adding a layer one time won't solve purpose. ORACLE data is continuously being changed by other applications. – Deep Sep 7 '12 at 20:14

Saving it as layer can resolve the issue since layer will take data from data source. so use this saved layer in the model. I need to do some rigorous testing since in my case an app is changing the data in source simultaneously to server side GP model run.

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