Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Paging/slicing/limiting doesn't work with order_by #62

Open
sethdenner opened this issue Apr 14, 2016 · 1 comment
Open

Paging/slicing/limiting doesn't work with order_by #62

sethdenner opened this issue Apr 14, 2016 · 1 comment

Comments

@sethdenner
Copy link
Contributor

sethdenner commented Apr 14, 2016

Assuming column "b" is the first column in your column family's clustering key;
if you make a query like:

model.objects.filter(a='foo').order_by('-b')[:3]

It seems that the results don't honor the order_by since they come back in the original order as stored in the database and not reversed.

@sethdenner
Copy link
Contributor Author

order_by works correctly if you do not slice the queryset.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant