#11188 closed (fixed)
Contradiction in queryset documentation re slices
| Reported by: | anonymous | Owned by: | Karen Tracey |
|---|---|---|---|
| Component: | Documentation | Version: | dev |
| Severity: | Keywords: | ||
| Cc: | Triage Stage: | Accepted | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
There seems to be a contradiction in the "Limiting Queryset" documentation at
http://docs.djangoproject.com/en/dev/topics/db/queries/#id4
as it pertains to the third 'step' pamameter in slices.
It states that
'Negative indexing (i.e. Entry.objects.all()[-1]) is not supported, nor is the third "step" slice parameter.'
The next paragraph, however, explains how things work when the "step" parameter is used. It seems, then, that the "step" parameter *is* supported. This appears to be a contradiction.
Change History (3)
comment:1 by , 16 years ago
| Owner: | changed from to |
|---|---|
| Status: | new → assigned |
| Triage Stage: | Unreviewed → Accepted |
comment:2 by , 16 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
Note:
See TracTickets
for help on using tickets.
That note was added in r10371, I'm not sure why. The ticket that requests a note on negative indexing not being supported doesn't mention step, and a cursory search for a ticket that might have triggered that note (as r10371 fixed bunches of tickets) doesn't reveal it. Testing shows
stepis indeed supported so the note is wrong.