Greetings. I am getting this error when I do a Select_analysis on a polygon feature class. I scoured the web and cannot find a reference to what this means. Trying to write to a feature class that already exists? Below is the code and message. It is crashing on the last line of the code. Thanks.
print "Creating subset of matching input polys..."
arcpy.Select_analysis(InputPolysAll,LocResPolysTemp,"Year = "+Year)
arcpy.Dissolve_management(LocResPolysTemp,LocResPolys,"LocRes")
arcpy.AddField_management(LocResPolys,"KEEP","SHORT")
arcpy.CalculateField_management(LocResPolys,"KEEP","0","PYTHON")
arcpy.MakeTableView_management(LocResPolys,"LocResPolysAsTableView")
arcpy.AddJoin_management("LocResPolysAsTableView","LocRes",LocResTableUnique,"LocRes","KEEP_COMMON")
arcpy.CalculateField_management("LocResPolysAsTableView","KEEP","1","PYTHON")
arcpy.RemoveJoin_management("LocResPolysAsTableView")
arcpy.Select_analysis(LocResPolys,LocResPolysMatch, "KEEP = 1")
print ""
Executing: Select InputPolys_LocRes_YBDTRRS_2017 D:\Users\rowright\Documents\ArcGIS\Default.gdb\MatchPolys_LocRes_YBDTRRS_2017 "KEEP = 1"
Start Time: Thu Nov 16 09:08:24 2017
ERROR 000433: The output must be the same as input
Failed to execute (Select).
Solved! Go to Solution.
Resolved: I had inadvertently changed the path of the identified workspace by one letter e.g.,
arcpy.env.workspace = r"D:\WildlifeHealth\CWD_2017\GIS\RandomLocWork\Processing.gdb" vs
arcpy.env.workspace = r"D:\WildlifeHealth\CWD_2017\GIS\RandomLocsWork\Processing.gdb".
I am still curious about the error message though. I have never seen it before and was unable to find any reference to it.
Thanks.
Bob
could you try to emulate what is shown in the help topic
where_clause = '"CLASS" = \'4\''
# perhaps
where_clause = '"KEEP" = \'1\''
Resolved: I had inadvertently changed the path of the identified workspace by one letter e.g.,
arcpy.env.workspace = r"D:\WildlifeHealth\CWD_2017\GIS\RandomLocWork\Processing.gdb" vs
arcpy.env.workspace = r"D:\WildlifeHealth\CWD_2017\GIS\RandomLocsWork\Processing.gdb".
I am still curious about the error message though. I have never seen it before and was unable to find any reference to it.
Thanks.
Bob
My guess, if it was suppose to read/write from the same folder, and the output was defaulting to the env.workspace (which it couldn't find, so it tried the default .gdb) and the input maybe was explicitly set....it didn't like it. Typos can cause strange errors if it can't find the path/gdb. my 2 cents.