Sum aggregate support for both grouped & ungrouped queries