Wednesday, March 2, 2016

Re: GROUP BY without using aggregate function



On Wednesday, March 2, 2016 at 6:11:32 PM UTC+1, Dan Tagg wrote:
if your aren't counting or averaging then why are you grouping?



To fast find distinct values within big dataset - some queries on some engines may be faster when using grouping. 
It was known technique years ago and I'm still using it.

Marcin

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/9aa22036-4537-4734-b2d5-93cc625b09f9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment