Uh oh!
There was an error while loading. Please reload this page.
[SPARK-29107][SQL][TESTS] Port window.sql (Part 1) - #25816
Conversation
wangyum
commented
Sep 17, 2019
ok to test |
SparkQA
commented
Sep 17, 2019
Test build #110785 has started for PR 25816 at commit |
shaneknapp
commented
Sep 17, 2019
test this please |
SparkQA
commented
Sep 17, 2019
Test build #110801 has finished for PR 25816 at commit
|
maropu
left a comment
There was a problem hiding this comment.
LGTM except for some minor comments. @wangyum@HyukjinKwon
| -- Portions Copyright (c) 1996-2019, PostgreSQL Global Development Group | ||
| -- | ||
| -- Window Functions Testing | ||
| -- https://github.com/postgres/postgres/blob/REL_12_BETA3/src/test/regress/sql/window.sql |
There was a problem hiding this comment.
Can you add line numbers?:
There was a problem hiding this comment.
Unfortunately,REL_12_BETA4 is released.
https://github.com/postgres/postgres/blob/REL_12_BETA4/src/test/regress/sql/window.sql
There was a problem hiding this comment.
I can update to match Beta4, but:
- If the PgSQL version is that relevant, then we will add a new JIRA for every new PgSQL release for every .sql migration (i.e: strings.sql, union.sql, date.sql, aggregates.sql, etc). But we didn't.
- If the PgSQL is not that relevant, then there's no need to change PRs to match the latest release candidate version (although it matches a stable version).
What you think?
There was a problem hiding this comment.
Have you checked the last discussion? #24850 (comment)
I think we don't need to stick to the single snapshot, so its ok to update it to REL_12_BETA4 in this port. Actually, no difference between BETA2 and BETA4 in window.sql?
There was a problem hiding this comment.
No, I didn't get noticed that you guys were already discussing about updating other tests.
I checked last week and there are some major differences between BETA2 and BETA4 for window.sql, I just can't remember if lines L1-L319 are impacted by them. So, it's ok to keep at REL2 or should I updated to REL3?
| SELECT sum(salary) OVER w, rank() OVER w FROM empsalary WINDOW w AS (PARTITION BY depname ORDER BY salary DESC); | ||
| -- strict aggs | ||
| -- Temporarily turns off the ANSI mode because of compatibility issues between keywords |
| FROM tenk1 WHERE unique1 < 10; | ||
| -- [SPARK-28428] Spark `exclude` always expecting `()` | ||
| SELECT sum(unique1) over (w range between current row and unbounded following), |
There was a problem hiding this comment.
Why didn't you comment out this statement? You did the other statements, though?
Uh oh!
There was an error while loading. Please reload this page.
HyukjinKwon
commented
Sep 29, 2019
ping @DylanGuedes to update |
DylanGuedes
commented
Sep 29, 2019
@HyukjinKwon I updated with the changes suggested, but still not clear: should I update to REL4? |
SparkQA
commented
Sep 29, 2019
Test build #111564 has finished for PR 25816 at commit
|
HyukjinKwon
commented
Sep 29, 2019
Yea, we should update it. |
SparkQA
commented
Sep 29, 2019
Test build #111567 has finished for PR 25816 at commit
|
| 3 9 25 9 | ||
| -- !query 43 |
There was a problem hiding this comment.
This test seems failing when it's ran via the thrift server. Can you check the cause and exclude this in the test? cc @wangyum
SparkQA
commented
Sep 29, 2019
Test build #111571 has finished for PR 25816 at commit
|
| -- SELECT four, ten/4 as two, | ||
| -- sum(ten/4) over (partition by four order by ten/4 range between unbounded preceding and current row), | ||
| -- last(ten/4) over (partition by four order by ten/4 range between unbounded preceding and current row) | ||
| -- FROM (select distinct ten, four from tenk1) ss; |
There was a problem hiding this comment.
Ur, did you regenerate the golden files after this removal?
SparkQA
commented
Sep 29, 2019
Test build #111575 has finished for PR 25816 at commit
|
SparkQA
commented
Oct 2, 2019
Test build #111661 has finished for PR 25816 at commit
|
dongjoon-hyun
commented
Oct 3, 2019
Hmm. Still @DylanGuedes . Could you post the query result in both |
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
DylanGuedes
commented
Oct 8, 2019
It works fine locally. And, to be fair, I have no idea why this is not working: in my older PR It also always passed. I'll remote both queries that are failing. |
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
SparkQA
commented
Oct 8, 2019
Test build #111862 has finished for PR 25816 at commit
|
dongjoon-hyun
commented
Oct 13, 2019
Retest this please. |
| last(ten) over (partition by four order by ten range between unbounded preceding and unbounded following) | ||
| FROM (select distinct ten, four from tenk1) ss; | ||
| -- Failing on thrift server |
There was a problem hiding this comment.
We need a JIRA issue if we are not going to cover this query.
| -- last(ten/4) over (partition by four order by ten/4 range between unbounded preceding and current row) | ||
| -- FROM (select distinct ten, four from tenk1) ss; | ||
| -- Failing on thrift server |
There was a problem hiding this comment.
We need a JIRA issue if we are not going to cover this query, too.
dongjoon-hyun
left a comment
There was a problem hiding this comment.
I know this consumed your time your time, @DylanGuedes .
I believe the followings are the final pieces.
- A new JIRA for the newly excluded query 1: #25816 (comment)
- A new JIRA for the newly excluded query 2: #25816 (comment)
- Fix the PR inconsistency. (1) PR description has a link to
REL_12_BETA2. (2) Code has a link toREL_12_BETA4. (3) The latest one is alreadyREL_12_STABLE. The best option is to sync withREL_12_STABLE. Could you check the diff? I believe there is no diff on this file. Then, we can useREL_12_STABLE.
cc @maropu , too.
I checked the diff. There is additional addition from line 1257, but that is irrelevant to this PR because this PR is only for line 1 to line 319. Please simply update the link with |
SparkQA
commented
Oct 13, 2019
Test build #111988 has finished for PR 25816 at commit
|
Signed-off-by: DylanGuedes <djmgguedes@gmail.com>
SparkQA
commented
Oct 13, 2019
Test build #111995 has finished for PR 25816 at commit
|
dongjoon-hyun
left a comment
There was a problem hiding this comment.
+1, LGTM. Thank you, @DylanGuedes , @maropu , @HyukjinKwon !
Merged to master for this.
gengliangwang
commented
Oct 14, 2019
I have created a followup to correct the file location: #26116 |
dongjoon-hyun
commented
Oct 14, 2019
Oops. Yes. We moved the location and this PR is very old. |
dongjoon-hyun
commented
Oct 14, 2019
I missed the location, @DylanGuedes . And, thank you again, @gengliangwang ! |
DylanGuedes
commented
Oct 15, 2019
@dongjoon-hyun I made a new PR with the new location. |
What changes were proposed in this pull request?
This PR ports window.sql from PostgreSQL regression tests https://github.com/postgres/postgres/blob/REL_12_BETA2/src/test/regress/sql/window.sql from lines 1~319
The expected results can be found in the link: https://github.com/postgres/postgres/blob/REL_12_BETA2/src/test/regress/expected/window.out
How was this patch tested?
Pass the Jenkins.
Why are the changes needed?
To ensure compatibility with PGSQL
Does this PR introduce any user-facing change?
No
How was this patch tested?
Comparison with PgSQL results.