Tag: django-orm
37 Posts
Django: Use a Proxy Model to Split Views of Your Data Without Creating Another Table
Django: Sort QuerySets the Right Way with order_by() and Meta.ordering in 5 Minutes
Django: Roll Back Part of a Transaction with Savepoints — Stop Losing the Whole Batch When One Row Fails
Django: Use @cached_property to Compute Once and Reuse Many Times in a Model
Django: Add Extra Fields to a ManyToMany Relationship with a Through Model in 5 Minutes
Django: Use get_object_or_404() Instead of try/except DoesNotExist — Return a Proper 404 in One Line
Django: Build a Like Button for Every Model with GenericForeignKey — No More Duplicate Tables
Django: Back Up and Restore Data with dumpdata and loaddata in 5 Minutes
