I am trying to assign a value to two shapefiles in the first data frame of my .mxd with definition query, but it seems that cannot be done.
Any suggestion? Thanks
Here is the code:
mxd = arcpy.mapping.MapDocument("CURRENT")
df = arcpy.mapping.ListDataFrames(mxd)
for lyr in arcpy.mapping.ListLayers(mxd):
if lyr.name == "waste":
lyr.definitionQuery == "Code = 'IT1300021'"