I am using a Python script in ESRI ArcGIS Desktop to call a complex SQL query While still fairly new to Python in the ESRI envoriment I have had some success and am now being asked a larger task. Part of the solution to this task requires 'calling' an SQL script, developed by a colleague to, into ESRI ArcGIS Desktop v10.4, My plan is to call several parameters from the user (date time frame, priority classifications etc) from a Desktop interface which will then pass these variables into the SQL code.
I have created the Query layers for the SQL tables which are called by the developed
SQL code (DSQL here on) and am experimenting with calling SQL. So far I can get simple
queries accomplished but have not yet figured out how to run case statements etc.
So far my Python script is very rudimentary and will remain such until I have the SQL.
I will post the code and my attempts to resolve my challenges as I go.