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

Don't count first when we're doing a real query. #60

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

emezeske
Copy link

@emezeske emezeske commented May 2, 2012

Using the appstats tool for my GAE project, I found that counting the entities in a query before executing it took about 160% as long as just executing the query (with no count). Unless it is expected that most queries will return zero results, counting first doesn't make sense.

Using the appstats tool for my GAE project, I found that counting the
entities in a query before executing it took about 160% as long as just
executing the query (with no count).  Unless it is expected that most
queries will return zero results, counting first doesn't make sense.
@gcv
Copy link
Owner

gcv commented May 2, 2012

Nice catch. Your patch looks pretty good, I'll merge it in for the next version of appengine-magic.

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

Successfully merging this pull request may close these issues.

2 participants