summaryrefslogtreecommitdiff
path: root/django/db/backends/postgresql/base.py
Commit message (Collapse)AuthorAgeFilesLines
...
* Refs #23919 -- Removed unneeded force_str callsClaude Paroz2017-01-201-2/+1
|
* Refs #23919 -- Removed six.PY2/PY3 usageClaude Paroz2017-01-181-4/+0
| | | | Thanks Tim Graham for the review.
* Refs #26154 -- Removed deprecated CommaSeparatedIntegerField.Tim Graham2017-01-171-1/+0
|
* Refs #16614 -- Called _prepare_cursor() on every created cursor.François Freitag2017-01-161-2/+1
|
* Refs #16614 -- Made QuerySet.iterator() use server-side cursors on PostgreSQL.François Freitag2017-01-111-2/+23
| | | | | | | Thanks to Josh Smeaton for the idea of implementing server-side cursors in PostgreSQL from the iterator method, and Anssi Kääriäinen and Kevin Turner for their previous work. Also Simon Charette and Tim Graham for review.
* Fixed E305 flake8 warnings.Ramin Farajpour Cami2016-11-141-0/+1
|
* Removed DatabaseError and IntegrityError declarations from database backends.Adam Chainz2016-09-261-4/+1
| | | Unused since 11ee9746a0530ec38f523fb4de44950d9b783877.
* Fixed #27170 -- Added DatabaseWrapper class attributes to ease subclassing.Chris Jerdonek2016-09-081-11/+6
|
* Removed unnecessary registration of psycopg2 unicode extensions on Python 3Claude Paroz2016-08-151-2/+4
|
* Fixed #26712 -- Avoided unnecessary SET TIMEZONE queries on PostgreSQL.Simon Charette2016-06-061-8/+12
| | | | | A change of the USE_TZ or TIME_ZONE settings doesn't necessarily require a change to the active connections' timezones.
* Fixed E402 flake8 warnings.Tim Graham2016-04-041-8/+8
|
* Fixed #26177 -- Fixed a PostgreSQL crash with TIME_ZONE=None and USE_TZ=False.Tim Graham2016-02-081-1/+1
|
* Fixed #14286 -- Added models.BigAutoField.Alexander Sosnovskiy2015-12-251-0/+1
|
* Fixed #25329 -- Prevented _nodb_connection from being left openAdam Chainz2015-09-111-1/+1
|
* Fixed #25175 -- Renamed the postgresql_psycopg2 database backend to postgresql.Caio Ariede2015-08-071-0/+264
|
* Deprecated the psycopg-based postgresql database backend.Russell Keith-Magee2011-04-021-183/+0
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@15980 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #7539, #13067 -- Added on_delete argument to ForeignKey to control ↵Carl Meyer2010-11-091-0/+1
| | | | | | cascade behavior. Also refactored deletion for efficiency and code clarity. Many thanks to Johannes Dollinger and Michael Glassford for extensive work on the patch, and to Alex Gaynor, Russell Keith-Magee, and Jacob Kaplan-Moss for review. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14507 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14223 -- Extended unification of exception raised in presence of ↵Ramiro Morales2010-10-231-0/+7
| | | | | | | | | | integrity constraint violations. The unification had been introduced in r12352 and native backend exceptions still slipped through in cases that end in connection.commit() call. Thanks Alex, Jacob and Carl for reviewing. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14320 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12991 -- Added unittest2 support. Thanks to PaulM for the draft ↵Russell Keith-Magee2010-10-111-1/+4
| | | | | | patch, and to Luke, Karen, Justin, Alex, Łukasz Rekucki, and Chuck Harmston for their help testing and reviewing the final patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14139 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14436 -- Escalated 1.2 PendingDeprecationWarnings to ↵Russell Keith-Magee2010-10-111-1/+1
| | | | | | DeprecationWarnings, and removed 1.1 deprecated code. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14138 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #13798 -- Added connection argument to the connection_created signal. ↵Russell Keith-Magee2010-08-301-2/+3
| | | | | | Thanks to liangent for the report, and Alex Gaynor for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13672 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12766 -- Only set the psycopg1 client encoding when the connection is ↵Russell Keith-Magee2010-03-251-3/+2
| | | | | | first created. This allows the custom_pk test to pass under psycopg1. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12848 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12759 -- Fixed the iterator method on psycopg1 cursors, which was ↵Russell Keith-Magee2010-03-251-1/+1
| | | | | | preventing the raw_query tests from passing. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12845 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Corrected an edge case introduced in r12602. Thanks to Ramiro Morales for ↵Russell Keith-Magee2010-02-261-2/+5
| | | | | | the eagle eyes. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12605 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #1480 -- Added the ability to use the system timezone. Thanks to ↵Russell Keith-Magee2010-02-261-1/+1
| | | | | | Ramiro Morales for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12602 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* No, really this time -- corrected the warning message from r12510.Russell Keith-Magee2010-02-231-1/+1
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@12512 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Cleaned up the warning message introduced by r12510.Russell Keith-Magee2010-02-231-1/+1
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@12511 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12912 -- Placed the psycopg1-backed ``postgresql`` database backend ↵Russell Keith-Magee2010-02-231-0/+6
| | | | | | on the deprecation path. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12510 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed a regression in the Postgres psycopg cursor handling introduced by ↵Russell Keith-Magee2010-02-031-1/+1
| | | | | | r12352. Thanks to Kenneth Gonsalves for the report, and Karen for the fix. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12378 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12732 -- Corrected an argument naming problem introduced by r12532. ↵Russell Keith-Magee2010-01-301-1/+1
| | | | | | Thanks to stevedegrace for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12359 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12702 -- Introduced a common implementation of DatabaseError and ↵Russell Keith-Magee2010-01-291-3/+16
| | | | | | IntegrityError, so that database backends can (re)raise common error classes. Thanks for Waldemar Kornewald for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12352 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #1142 -- Added multiple database support.Russell Keith-Magee2009-12-221-15/+15
| | | | | | | | | | | | | | | | | This monster of a patch is the result of Alex Gaynor's 2009 Google Summer of Code project. Congratulations to Alex for a job well done. Big thanks also go to: * Justin Bronn for keeping GIS in line with the changes, * Karen Tracey and Jani Tiainen for their help testing Oracle support * Brett Hoerner, Jon Loyens, and Craig Kimmerer for their feedback. * Malcolm Treddinick for his guidance during the GSoC submission process. * Simon Willison for driving the original design process * Cal Henderson for complaining about ponies he wanted. ... and everyone else too numerous to mention that helped to bring this feature into fruition. git-svn-id: http://code.djangoproject.com/svn/django/trunk@11952 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Corrected PostgreSQL version comparisons from r10730. Thanks to rozwell for ↵Russell Keith-Magee2009-05-111-1/+1
| | | | | | the report on IRC. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10735 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #10842 -- Corrected parsing of version numbers for PostgreSQL 8.4beta ↵Russell Keith-Magee2009-05-101-1/+1
| | | | | | series. Thanks to hgdeoro for the report and fix. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10730 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #6064 -- Added the `connection_created` signal for when a database ↵Justin Bronn2009-03-291-0/+2
| | | | | | connection is created. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10182 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #10459 -- Refactored the internals of database connection objects so ↵Adrian Holovaty2009-03-111-14/+15
| | | | | | | | | | | | | | | | | that connections know their own settings and pass around settings as dictionaries instead of passing around the Django settings module itself. This will make it easier for multiple database support. Thanks to Alex Gaynor for the initial patch. This is backwards-compatible but will likely break third-party database backends. Specific API changes are: * BaseDatabaseWrapper.__init__() now takes a settings_dict instead of a settings module. It's called settings_dict to disambiguate, and for easy grepability. This should be a dictionary containing DATABASE_NAME, etc. * BaseDatabaseWrapper has a settings_dict attribute instead of an options attribute. BaseDatabaseWrapper.options is now BaseDatabaseWrapper['DATABASE_OPTIONS'] * BaseDatabaseWrapper._cursor() no longer takes a settings argument. * BaseDatabaseClient.__init__() now takes a connection argument (a DatabaseWrapper instance) instead of no arguments. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10026 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #8592 -- Fixed a bug in the way savepoint usage was disabled forMalcolm Tredinnick2008-08-281-5/+4
| | | | | | | PostgreSQL < 8.0. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8648 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #3575: use UPPER() instead ILIKE for postgres case-insensitive ↵Jacob Kaplan-Moss2008-08-251-4/+4
| | | | | | comparisons. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8536 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Do not use savepoints with PostgreSQL prior to 8.0.Malcolm Tredinnick2008-08-121-0/+7
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@8317 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Added savepoint support to the transaction code.Malcolm Tredinnick2008-08-121-2/+5
| | | | | | | | | | This is a no-op for most databases. Only necessary on PostgreSQL so that we can do things which will possibly intentionally raise an IntegrityError and not have to rollback the entire transaction. Not supported for PostgreSQL versions prior to 8.0, so should be used sparingly in internal Django code. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8314 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #5461 -- Refactored the database backend code to use classes for the ↵Russell Keith-Magee2008-08-111-7/+16
| | | | | | creation and introspection modules. Introduces a new validation module for DB-specific validation. This is a backwards incompatible change; see the wiki for details. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8296 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #5883 -- Added __iter__ methods to the debug cursor and the postgresql ↵Malcolm Tredinnick2008-03-171-0/+3
| | | | | | backend cursor. git-svn-id: http://code.djangoproject.com/svn/django/trunk@7259 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Changed postgresql and postgresql_psycopg2 backends NOT to do a SELECT ↵Adrian Holovaty2007-08-251-3/+0
| | | | | | version() for every connection, which was ludicrous. Now the version is only retrieved if it needs to be, via a lazy loader. git-svn-id: http://code.djangoproject.com/svn/django/trunk@6012 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Made various negligible formatting cleanups to the database backendsAdrian Holovaty2007-08-201-3/+3
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@5983 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Refactored OPERATOR_MAPPING so that it exists as ↵Adrian Holovaty2007-08-201-17/+16
| | | | | | django.db.connection.operators instead of django.db.backend.OPERATOR_MAPPING. Refs #5106 git-svn-id: http://code.djangoproject.com/svn/django/trunk@5982 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Implemented BaseDatabaseFeatures and changed all code to access it -- ↵Adrian Holovaty2007-08-201-10/+5
| | | | | | connection.features.foo instead of backend.foo git-svn-id: http://code.djangoproject.com/svn/django/trunk@5974 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Moved postgresql backend DatabaseOperations class into a new module, ↵Adrian Holovaty2007-08-201-108/+4
| | | | | | postgresql/operations.py, so that it can be imported by both the postgresql and postgresql_psycopg2 backends. Hence the two backends no longer have a duplicated DatabaseOperations class git-svn-id: http://code.djangoproject.com/svn/django/trunk@5972 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Removed backend.dictfetchall(), as it wasn't being used anywhereAdrian Holovaty2007-08-201-4/+0
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@5970 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Removed backend.dictfetchmany(), as it wasn't being used anywhereAdrian Holovaty2007-08-201-4/+0
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@5969 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Removed backend.dictfetchone(), as it wasn't being used anywhereAdrian Holovaty2007-08-201-4/+0
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@5968 bcc190cf-cafb-0310-a4f2-bffc1f526a37