Using arcpy for ArcGIS 10.5.1, I'm joining a feature layer to a table using arcpy.AddJoin_management()
with the KEEP_ALL
option in order to keep all features whether they have a related record in the joined table or not. However, after running the join, the only features in the layer are those that have a related record in the joined table.
My code is:
arcpy.MakeFeatureLayer_management(inFeatures, tmpLayer)
arcpy.MakeTableView_management(joinTable, tmpView, "Classification = '{}'".format(seasonClassification))
arcpy.AddJoin_management(tmpLayer, inField, tmpView, joinField, join_type="KEEP_ALL")
I know I've had this working as expected in other scripts, but not in this case.
What am I doing wrong? How do I get it to keep all features after the join?