﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
14626	DateField with auto_now=True is not coming in as Python's datetime.date object in Python 2.4 / 2.5	mischko	nobody	"Oracle backend with cx_Oracle 5.0.4
Python 2.4.3
Oracle 11
{{{
class scott_test1(models.Model):
    graphic_id = models.IntegerField()
    graphic_desc = models.CharField(max_length=30)
    curves = models.TextField()
    graphic_type = models.CharField(max_length=4)
    df = models.DateField(null=True, auto_now = True) # datetime.date
    dtf = models.DateTimeField(null=True, auto_now = True) # datetime.datetime
    tf = models.TimeField(null=True, auto_now =True) # datetime.time

foo=scott_test1(graphic_id=2,graphic_desc=""here is some text"", curves= "", "".join([str(x * 3.1514) for x in xrange(1000)]), graphic_type=""none"")

foo.save()
}}}
According to the docs at http://docs.djangoproject.com/en/dev/ref/models/fields/#datefield, foo.df should be a datetime.date object, not datetime.datetime:
{{{
In [7]: foo.df
Out[7]: datetime.datetime(2010, 11, 5, 10, 13, 3, 744903)

In [8]: foo.dtf
Out[8]: datetime.datetime(2010, 11, 5, 10, 13, 3, 745076)

In [9]: foo.tf
Out[9]: datetime.time(10, 13, 3, 745130)

}}}"		closed	Database layer (models, ORM)	1.2		duplicate			Unreviewed	0	0	0	0	0	0
