Fix exception in case of no aggregate results