Hello,
I'm running a stand alone script that, early on, uses arcpy.management.MakeFeatureLayer() with a simple where clause defining the data I want included.
Later in the script, I use that feature layer as the input for arcpy.management.Project(). Unfortunately, the output of the Project tool does not honor the SQL query applied to the feature layer.
Is this expected behavior? If not, any suggestions on how to troubleshoot why it's not being honored?
P.S. I asked ChatGPT this question and received a self-contradicting answer: it initially stated that this behavior is expected and that the Project() tool does not honor a feature layer's definition query, but then went on to suggest creating a feature layer with a where clause and feeding that as the input to the Project() tool.
EDIT: I just inserted a line into my script to return a message giving the feature count of the feature layer immediately before the Project() tool uses it as input and the feature count returned is still limited by the where clause. So, I have to conclude that the Project() tool just ignores the query (I'm still not sure if this is by design or not).