Skip to content

djangodocs

Django 1.10
  • 6.1 current
  • 6.0
  • 5.2 LTS
  • 5.1 unsupported
  • 5.0 unsupported
  • 4.2 unsupported
  • 4.1 unsupported
  • 4.0 unsupported
  • 3.2 unsupported
  • 3.1 unsupported
  • 3.0 unsupported
  • 2.2 unsupported
  • 2.1 unsupported
  • 2.0 unsupported
  • 1.11 unsupported
  • 1.10 unsupported
Polski
  • English
  • Français
  • 日本語
  • Bahasa Indonesia
  • Português (Brasil)
  • Español
  • Ελληνικά
  • Polski
Documentation contents
  • Dokumentacja Django
  • Pierwsze kroki
  • Using Django
    • How to install Django
    • Models and databases
      • Models
      • Making queries
      • Aggregation
      • Search
      • Managers
      • Performing raw SQL queries
      • Database transactions
      • Multiple databases
      • Tablespaces
      • Database access optimization
      • Examples of model relationship API usage
    • Handling HTTP requests
    • Working with forms
    • Templates
    • Class-based views
    • Migrations
    • Managing files
    • Testing in Django
    • User authentication in Django
    • Django’s cache framework
    • Conditional View Processing
    • Cryptographic signing
    • Sending email
    • Internationalization and localization
    • Logging
    • Pagination
    • Porting to Python 3
    • Security in Django
    • Performance and optimization
    • Serializing Django objects
    • Django settings
    • Signals
    • System check framework
    • External packages
  • „How-to” guides
  • Często zadawane pytania odnośnie Django
  • API Reference
  • Meta-documentation and miscellany
  • Glosariusz
  • Informacje o wydaniach
  • Django internals
Django 1.10 is no longer supported. It receives no security fixes. Use it for reference only. Latest release
Polish translation. Untranslated passages appear in English. 27.5% Help translate
  1. Django 1.10
  2. Using Django

Models and databasesLink to this heading#

A model is the single, definitive source of data about your data. It contains the essential fields and behaviors of the data you’re storing. Generally, each model maps to a single database table.

  • Models
  • Making queries
  • Aggregation
  • Search
  • Managers
  • Performing raw SQL queries
  • Database transactions
  • Multiple databases
  • Tablespaces
  • Database access optimization
  • Examples of model relationship API usage

This page as Markdown JSON

Edit this page on GitHub Official version

PreviousHow to install Django NextModels

An unofficial rendering of the Django documentation.

Not affiliated with or endorsed by the Django Software Foundation. The documentation is copyright © Django Software Foundation and individual contributors, and is used under the BSD 3-Clause licence. “Django” is a trademark of the Django Software Foundation.

This translation is the work of the Django i18n community, not of this site. Read the official documentation at docs.djangoproject.com.

👋 Jason Cartwright