w10schools
Login Register
  • Home
  • Tutorials
    • HTML, CSS
      • HTML, HTML5
      • CSS, CSS3
    • XML
    • JavaScript, AJAX
    • PHP
    • Ruby on Rails
      • Ruby
      • Rails
    • ASP.NET
      • ASP
      • C# .NET
    • Java
      • JSP
    • Databases
      • MySQL
      • MSSQL Server
      • Oracle
    • Web Server
      • Windows
      • Linux
      • Apache
      • IIS
    • Design
      • Dreamweaver
      • Flash
      • Photoshop
      • Fireworks
      • CorelDRAW
      • Illustrator
  • References
    • HTML
      • Bootstrap
    • CSS
      • CSS Selectors
      • Sass
    • JavaScript
    • Mobile Apps
      • Cordova
    • Ruby on Rails
      • Ruby
      • Rails
    • PHP
      • Function
      • Language
      • CodeIgniter
      • Phalcon
      • PHPUnit
      • Symfony
      • Drupal
      • Yii
      • Laravel
    • Perl
      • Perl
    • Python
      • Python
      • Django
      • NumPy
      • Pandas
      • scikit-image
      • scikit-learn
      • Statsmodels
      • Matplotlib
    • Lua
      • Lua
    • C, C++
      • C
      • C++
    • Server
      • Docker
      • Apache HTTP Server
      • Nginx
    • Database
      • PostgreSQL
    • Big Data
      • TensorFlow
    • Game Development
      • Phaser
      • LÖVE
  • Articles
    • News
    • General
      • Website Promotion
      • Online Advertising
      • Make Money Online
    • Editorials
    • Interviews
    • Web Roundups
  • Resources
    • Design
      • Fonts
      • Graphics
      • Vectors
      • Templates
      • UI (User Interface)
      • Brushes
      • Patterns, Backgrounds
      • Textures
    • Web Development
      • HTML, CSS
      • XML
      • JavaScript, AJAX
      • Ruby on Rails
      • PHP
      • Java
      • .NET
      • Python
      • Perl
      • Flash
    • Mobile Application Development
      • Mobile Development Tools
      • Swift
    • Online Services
      • Online Storage
      • Web Hosting
  • Tools
    • Generators
Edit
In Place Editing Advanced Editing
  • References
  • Python
  • Django
  • API
  • Models
  • QuerySet API reference

db.models.query.QuerySet.earliest()

earliest(field_name=None)

Works otherwise like latest() except the direction is changed.

Links:
  • https://docs.djangoproject.com/en/1.10/ref/models/querysets/#django.db.models.query.QuerySet.earliest
doc_Django
doc_Django
2025-01-10 15:47:30
Comments
Leave a Comment

Please login to continue.

Popular Articles
db.models.query.QuerySet class QuerySet(model=None, query=None, using=None) [source] Usually when you’ll interact with a QuerySet you’ll use it by chaining filters. To mak
db.models.query.QuerySet.using() using(alias) This method is for controlling which database the QuerySet will be evaluated against if you are using more than one database. The onl
db.models.query.QuerySet.delete() delete() Performs an SQL delete query on all rows in the QuerySet and returns the number of objects deleted and a dictionary with the number of de
db.models.query.QuerySet.create() create(**kwargs) A convenience method for creating an object and saving it all in one step. Thus: p = Person.objects.create(first_name="Bruce", la
db.models.query.QuerySet.count() count() Returns an integer representing the number of objects in the database matching the QuerySet. The count() method never raises exceptions. E


Return to View
  • Facebook
  • Tweet
  • Digg it
  • Stumbleupon
  • Delicious
  • Plus Share

Designed by : w10schools

service@w10schools.com

Our Partners: aeeble – Providing content publishing and search solutions