I have a huge database with Sightings from whales and dolphins from 1995 till today. So I want to sort the database with python.
Till now I can make FeatureLayers for each year
for year in range(1995,2014): arcpy.MakeFeatureLayer_management ("Sightings95-14", "test%s" % year, "DATE >= date'01.01.%s' AND DATE < date'01.01.%s'" % (year, year+1))
now I want to sort it into each month (no matter of the yaer), because there are way more sightings in may than in december for example.
If I excecut this code:
for month in range (01,12): arcpy.MakeFeatureLayer_management ("Sightings95-14", "test%s" % month, "DATE >= date'01.%s.1995' AND DATE < date'31.%s.2014'" % (month, month+1))
it makes the 12 FeatureLayers but in each Layer is the hole database included so he did not "sort" it right.
What is my mistake ?