summaryrefslogtreecommitdiff
path: root/tests/postgres_tests/models.py
AgeCommit message (Collapse)Author
2025-11-20Fixed #36748 -- Filtered non-standard placeholders from UNNEST queries.Chris Wesseling
2025-10-29Refs #35381 -- Delegated ArrayField element prepping to ↵Clifford Gama
base_field.get_db_prep_save. Previously, ArrayField always used base_field.get_db_prep_value when saving, which could differ from how base_field prepares data for save. This change overrides ArrayField.get_db_prep_save to delegate to the base_field's get_db_prep_save, ensuring elements like None in JSONField arrays are saved correctly as SQL NULL instead of JSON null.
2025-09-05Fixed #36564 -- Changed DEFAULT_AUTO_FIELD from AutoField to BigAutoField.Tim Graham
2025-01-20Fixed #36107 -- Adjusted UNNEST bulk_create strategy to opt-out sized arrays.Simon Charette
The array fields opt-out heuristic failed to account for sized arrays. Note that we keep relying on db_type as opposed to performing an ArrayField instance check against the column's field as there could be other implementations of model fields that use Postgres arrays to store the optimization must be disabled for all of them. Refs #35936. Thanks Claude Paroz for the report and test.
2024-08-05Fixed #35638 -- Updated validate_constraints to consider db_default.David Sanders
2023-09-18Refs #33872 -- Removed ↵Mariusz Felisiak
django.contrib.postgres.fields.CIText/CICharField/CIEmailField/CITextField. Per deprecation timeline.
2022-08-03Fixed #33872 -- Deprecated ↵Mariusz Felisiak
django.contrib.postgres.fields.CIText/CICharField/CIEmailField/CITextField.
2022-02-07Refs #33476 -- Reformatted code with Black.django-bot
2021-11-04Fixed #27147 -- Allowed specifying bounds of tuple inputs for non-discrete ↵Guilherme Martins Crocetti
range fields.
2021-10-01Refs #32943 -- Added support for covering SP-GiST indexes on PostgreSQL 14+.Nick Pope
2021-09-27Fixed #33114 -- Defined default output_field of StringAgg.ali
Thanks Simon Charette for the review.
2021-09-17Fixed #32492 -- Added TrigramWordSimilarity() and TrigramWordDistance() on ↵Nikita Marchant
PostgreSQL.
2020-12-03Refs #27095 -- Fixed test_contained_by_including_F_object when run in reverse.Mariusz Felisiak
Tests should not rely on auto PKs. Test regression in 33403bf80f635577a18426bc99c8a65e31fd8dfa.
2020-10-14Refs #32096 -- Fixed ExclusionConstraint crash with JSONField key transforms ↵Mariusz Felisiak
in expressions. Regression in 6789ded0a6ab797f0dcdfa6ad5d1cfa46e23abcd.
2020-10-14Refs #32096 -- Added test for ArrayAgg over JSONField key transforms.Mariusz Felisiak
2020-05-08Fixed #12990, Refs #27694 -- Added JSONField model field.sage
Thanks to Adam Johnson, Carlton Gibson, Mariusz Felisiak, and Raphael Michel for mentoring this Google Summer of Code 2019 project and everyone else who helped with the patch. Special thanks to Mads Jensen, Nick Pope, and Simon Charette for extensive reviews. Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-04-15Removed unused __str__() methods in tests models.Author: Mads Jensen
Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com> Co-Authored-By: Hasan Ramezani <hasan.r67@gmail.com>
2020-03-16Fixed #31340 -- Allowed query expressions in SearchQuery.value and __search ↵Baptiste Mispelon
lookup.
2019-12-05Fixed #31039 -- Added support for contained_by lookup with AutoFields, ↵Hasan Ramezani
SmallIntegerField, and DecimalField.
2019-11-01Refs #27808 -- Added test for saving nested ArrayField with nullable base field.Hasan Ramezani
2019-07-16Fixed #29824 -- Added support for database exclusion constraints on PostgreSQL.Mads Jensen
Thanks to Nick Pope and Mariusz Felisiak for review. Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2019-07-10Fixed #30621 -- Fixed crash of __contains lookup for Date/DateTimeRangeField ↵Mariusz Felisiak
when the right hand side is the same type. Thanks Tilman Koschnick for the report and initial patch. Thanks Carlton Gibson the review. Regression in 6b048b364ca1e0e56a0d3815bf2be33ac9998355.
2019-02-09Fixed #29391 -- Made PostgresSimpleLookup respect Field.get_db_prep_value().Vinay Karanam
2018-10-02Fixed #29598 -- Deprecated FloatRangeField in favor of DecimalRangeField.Stefano Chiodino
2018-09-18Fixed #23646 -- Added QuerySet.bulk_update() to efficiently update many models.Tom Forbes
2018-07-27Fixed #28291, #24726 -- Fixed ArrayField with JSONField and RangeFields.vinay karanam
2018-03-20Fixed #29227 -- Allowed BooleanField to be null=True.Tim Graham
Thanks Lynn Cyrin for contributing to the patch, and Nick Pope for review.
2017-10-20Fixed #28577 -- Added checks for ArrayField and JSONField to prevent mutable ↵Flávio Juvenal
defaults.
2017-09-27Fixed #28626 -- Dropped support for PostgreSQL 9.3.Tim Graham
Thanks Simon Charette for the introspection changes.
2017-07-20Fixed #28370 -- Deprecated the context arg of Field.from_db_value() and ↵Tim Graham
Expression.convert_value(). Unused since a0d166306fbdc41f49e6fadf4ec84b17eb147daa.
2017-05-04Fixed #28161 -- Fixed return type of ArrayField(CITextField()).Simon Charette
Thanks Tim for the review.
2017-05-03Added a test for ArrayField(HStoreField()).Simon Charette
2017-04-25Fixed #27996 -- Added RandomUUID function and CryptoExtension to ↵Paolo Melchiorre
contrib.postgres.
2017-02-11Refs #26610 -- Added CIText mixin and CIChar/Email/TextField.Mads Jensen
2017-01-25Refs #23919 -- Replaced super(ClassName, self) with super().chillaranand
2017-01-19Refs #23919 -- Stopped inheriting from object to define new style classes.Simon Charette
2016-09-22Fixed #27186 -- Fixed model form default fallback for MultiWidget, ↵Tim Graham
FileInput, SplitDateTimeWidget, SelectDateWidget, and SplitArrayWidget. Thanks Matt Westcott for the review.
2016-09-21Fixed #26610 -- Added CITextField to contrib.postgres.Mads Jensen
2016-09-12Used a database feature to prevent the jsonb test model from being migrated.Simon Charette
Thanks Tim for the review.
2016-08-25Fixed #25995 -- Added an encoder option to JSONFieldClaude Paroz
Thanks Berker Peksag and Tim Graham for the reviews.
2016-04-22Refs #3254 -- Added full text search to contrib.postgres.Marc Tamlyn
Adds a reasonably feature complete implementation of full text search using the built in PostgreSQL engine. It uses public APIs from Expression and Lookup. With thanks to Tim Graham, Simon Charettes, Josh Smeaton, Mikey Ariel and many others for their advice and review. Particular thanks also go to the supporters of the contrib.postgres kickstarter.
2016-03-15Fixed #25579 -- Fixed ArrayField.get_db_prep_value() to allow complex types.Matt C
2016-03-12Fixed #25143 -- Added ArrayField.from_db_value().Fernando Miranda
Thanks Karan Lyons for contributing to the patch.
2016-02-12Refs #25979 -- Dropped compatiblity for running tests on PostgreSQL < 9.2.Tim Graham
2015-07-27Fixed #21127 -- Started deprecation toward requiring on_delete for ↵Flavio Curella
ForeignKey/OneToOneField
2015-06-15Fixed #24894 -- Added contrib.postgres.functions.TransactionNowAdam Chainz
2015-06-04Fixed #24837 -- field__contained_by=RangeMarc Tamlyn
Provide `contained_by` lookups for the equivalent single valued fields related to the range field types. This acts as the opposite direction to rangefield__contains. With thanks to schinckel for the idea and initial tests.
2015-05-30Fixed #24604 -- Added JSONField to contrib.postgres.Marc Tamlyn
2015-04-18Stopped special-casing postgres-specific testsClaude Paroz
Refs #23879.
2015-03-30Fixed #24301 -- Added PostgreSQL-specific aggregate functionsAndriy Sokolovskiy