forked from apache/druid
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MSQ window functions: Fix partition boundary issues for arrays (apach…
…e#16780) * MSQ window functions: Fix partition boundary issues for arrays * Address review comments * Cache type strategies * Trigger Build * Convert typeStrategies from list to array
- Loading branch information
1 parent
302739a
commit a0437b6
Showing
8 changed files
with
90 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
.../test/resources/drill/window/queries/druid_queries/partition_by_array/wikipedia_query_1.e
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Austria null #de.wikipedia 1 | ||
Republic of Korea null #en.wikipedia 2 | ||
Republic of Korea null #ja.wikipedia 3 | ||
Republic of Korea null #ko.wikipedia 4 | ||
Republic of Korea Seoul #ko.wikipedia 1 | ||
Austria Vienna #de.wikipedia 1 | ||
Austria Vienna #es.wikipedia 2 | ||
Austria Vienna #tr.wikipedia 3 | ||
Republic of Korea Jeonju #ko.wikipedia 4 | ||
Republic of Korea Suwon-si #ko.wikipedia 1 | ||
Austria Horsching #de.wikipedia 1 | ||
Republic of Korea Seongnam-si #ko.wikipedia 1 | ||
Republic of Korea Yongsan-dong #ko.wikipedia 1 |
6 changes: 6 additions & 0 deletions
6
.../test/resources/drill/window/queries/druid_queries/partition_by_array/wikipedia_query_1.q
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
select | ||
countryName, cityName, channel, | ||
row_number() over (partition by array[1,2,length(cityName)] order by countryName) as c | ||
from wikipedia | ||
where countryName in ('Austria', 'Republic of Korea') | ||
group by countryName, cityName, channel |
13 changes: 13 additions & 0 deletions
13
.../test/resources/drill/window/queries/druid_queries/partition_by_array/wikipedia_query_2.e
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Austria null #de.wikipedia 1 | ||
Austria Horsching #de.wikipedia 2 | ||
Austria Vienna #de.wikipedia 3 | ||
Austria Vienna #es.wikipedia 4 | ||
Austria Vienna #tr.wikipedia 5 | ||
Republic of Korea null #en.wikipedia 6 | ||
Republic of Korea null #ja.wikipedia 7 | ||
Republic of Korea null #ko.wikipedia 8 | ||
Republic of Korea Jeonju #ko.wikipedia 9 | ||
Republic of Korea Seongnam-si #ko.wikipedia 10 | ||
Republic of Korea Seoul #ko.wikipedia 11 | ||
Republic of Korea Suwon-si #ko.wikipedia 12 | ||
Republic of Korea Yongsan-dong #ko.wikipedia 13 |
6 changes: 6 additions & 0 deletions
6
.../test/resources/drill/window/queries/druid_queries/partition_by_array/wikipedia_query_2.q
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
select | ||
countryName, cityName, channel, | ||
row_number() over (partition by array[1,2,3] order by countryName) as c | ||
from wikipedia | ||
where countryName in ('Austria', 'Republic of Korea') | ||
group by countryName, cityName, channel |
13 changes: 13 additions & 0 deletions
13
.../test/resources/drill/window/queries/druid_queries/partition_by_array/wikipedia_query_3.e
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
Austria null #de.wikipedia 1 | ||
Austria Vienna #de.wikipedia 1 | ||
Austria Vienna #es.wikipedia 2 | ||
Austria Vienna #tr.wikipedia 3 | ||
Austria Horsching #de.wikipedia 1 | ||
Republic of Korea null #en.wikipedia 1 | ||
Republic of Korea null #ja.wikipedia 2 | ||
Republic of Korea null #ko.wikipedia 3 | ||
Republic of Korea Seoul #ko.wikipedia 1 | ||
Republic of Korea Jeonju #ko.wikipedia 1 | ||
Republic of Korea Suwon-si #ko.wikipedia 1 | ||
Republic of Korea Seongnam-si #ko.wikipedia 1 | ||
Republic of Korea Yongsan-dong #ko.wikipedia 1 |
6 changes: 6 additions & 0 deletions
6
.../test/resources/drill/window/queries/druid_queries/partition_by_array/wikipedia_query_3.q
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
select | ||
countryName, cityName, channel, | ||
row_number() over (partition by array[1,length(countryName),length(cityName)] order by countryName) as c | ||
from wikipedia | ||
where countryName in ('Austria', 'Republic of Korea') | ||
group by countryName, cityName, channel |