I'm working on part of tool that will use arcpy.CalculateField_management to add the current date to the attribut table. I've wandered far and wide on the interwebs and can't seem to find the resolution to this issue.
When using this code, i get the value "12:00:00 AM"
input = r'C:\GIS\CARGIS\SHAPES.gdb\CRASH_ON_2013'
today = datetime.date.today()
dte = today.strftime('%m/%d/%Y')
arcpy.CalculateField_management(input,"DTCARXTRCT",dte,"PYTHON")
When using this code, I get the value "06/19/1905" from today's date of "10/07/2014"
input = r'C:\GIS\CARGIS\SHAPES.gdb\CRASH_ON_2013'
today = datetime.date.today()
dte = str(today)
arcpy.CalculateField_management(input,"DTCARXTRCT",dte,"PYTHON")
Any thoughts on what I'm doing wrong? I'd like to avoid using the update cursor, but will do so if it's the last option.