clintropolis commented on a change in pull request #10968:
URL: https://github.com/apache/druid/pull/10968#discussion_r590688337



##########
File path: 
processing/src/main/java/org/apache/druid/query/groupby/GroupByQuery.java
##########
@@ -715,7 +716,11 @@ private DateTime computeUniversalTimestamp()
     if (!timestampStringFromContext.isEmpty()) {
       return DateTimes.utc(Long.parseLong(timestampStringFromContext));
     } else if (Granularities.ALL.equals(granularity)) {
-      final DateTime timeStart = getIntervals().get(0).getStart();
+      final List<Interval> intervals = getIntervals();
+      if (CollectionUtils.isNullOrEmpty(intervals)) {
+        return null;

Review comment:
       Hmm, I didn't really think very hard about it, but nothing really made 
sense to me to use if there is no interval on the query so I went with null 
because its probably going to have no timestamps... does another value make 
more sense though?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to