Ticket #13282: 13282-r13135.2.diff

File 13282-r13135.2.diff, 939 bytes (added by Tim Graham, 15 years ago)

ramiro's patch with # for Saturday fixed from 6 to 7

  • docs/ref/models/querysets.txt

    diff --git a/docs/ref/models/querysets.txt b/docs/ref/models/querysets.txt
    a b  
    13831383
    13841384    SELECT ... WHERE id > 4;
    13851385
    1386 .. fieldlookup:: gte 
     1386.. fieldlookup:: gte
    13871387
    13881388gte
    13891389~~~
     
    15661566
    15671567For date/datetime fields, a 'day of the week' match.
    15681568
     1569Takes an integer value representing the day of week from 1 (Sunday) to 7
     1570(Saturday).
     1571
    15691572Example::
    15701573
    15711574    Entry.objects.filter(pub_date__week_day=2)
    15721575
    1573 SQL equivalent::
    1574 
    1575     SELECT ... WHERE EXTRACT('dow' FROM pub_date) = '2';
    1576 
    1577 (The exact SQL syntax varies for each database engine.)
     1576(No equivalent SQL code fragment is included for this lookup because
     1577implementation of the relevant query varies among different database engines.)
    15781578
    15791579Note this will match any record with a pub_date that falls on a Monday (day 2
    15801580of the week), regardless of the month or year in which it occurs. Week days
Back to Top