GQL, Aggregation and Order By
- by Koran
Hi,
How can GQL support ORDER BY when it does not support aggregation?
The question is - if say the result of the query is more than 1000, does ORDER BY return fully ordered list or only the first 1000 items which is then ordered?
To explain the question more: is conceptually MIN() same as query.orderby('asc').fetch(1)?
If it is properly ordering the list, then how can it not provide COUNT(), since to properly order the list, GQL possibly has to parse through the whole list - in which case, COUNT() is not an issue at all?
Or is item indexed and kept in some type of tree so that it does not need to parse it all the time?