mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Fixed #20292: Pass datetime objects (not formatted dates) as params to Oracle
This seems worthwhile in its own right, but also works around an Oracle bug (in versions 10 -- 11.1) where the use of Unicode would reset the date/time formats, causing ORA-01843 errors. Thanks Trac users CarstenF for the report, jtiai for the initial patch, and everyone who contributed to the discussion on the ticket.
This commit is contained in:
parent
fc79c3fb3d
commit
6983201cfb
3 changed files with 63 additions and 17 deletions
|
@ -76,6 +76,12 @@ class BooleanModel(models.Model):
|
|||
string = models.CharField(max_length=10, default='abc')
|
||||
|
||||
|
||||
class DateTimeModel(models.Model):
|
||||
d = models.DateField()
|
||||
dt = models.DateTimeField()
|
||||
t = models.TimeField()
|
||||
|
||||
|
||||
class PrimaryKeyCharModel(models.Model):
|
||||
string = models.CharField(max_length=10, primary_key=True)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue