You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kyuubi.apache.org by bo...@apache.org on 2023/02/27 01:39:38 UTC
[kyuubi] branch PR_4304 created (now 20ffed95e)
This is an automated email from the ASF dual-hosted git repository.
bowenliang pushed a change to branch PR_4304
in repository https://gitbox.apache.org/repos/asf/kyuubi.git
at 20ffed95e sort union result
This branch includes the following new commits:
new 20ffed95e sort union result
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
[kyuubi] 01/01: sort union result
Posted by bo...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
bowenliang pushed a commit to branch PR_4304
in repository https://gitbox.apache.org/repos/asf/kyuubi.git
commit 20ffed95e1a178e05db3b17af483d116c036a285
Author: liangbowen <li...@gf.com.cn>
AuthorDate: Mon Feb 27 09:38:18 2023 +0800
sort union result
---
.../spark/authz/ranger/datamasking/DataMaskingTestBase.scala | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/extensions/spark/kyuubi-spark-authz/src/test/scala/org/apache/kyuubi/plugin/spark/authz/ranger/datamasking/DataMaskingTestBase.scala b/extensions/spark/kyuubi-spark-authz/src/test/scala/org/apache/kyuubi/plugin/spark/authz/ranger/datamasking/DataMaskingTestBase.scala
index 7cc3dc6b6..15e5e96c4 100644
--- a/extensions/spark/kyuubi-spark-authz/src/test/scala/org/apache/kyuubi/plugin/spark/authz/ranger/datamasking/DataMaskingTestBase.scala
+++ b/extensions/spark/kyuubi-spark-authz/src/test/scala/org/apache/kyuubi/plugin/spark/authz/ranger/datamasking/DataMaskingTestBase.scala
@@ -228,10 +228,16 @@ trait DataMaskingTestBase extends AnyFunSuite with SparkSessionProvider with Bef
}
test("union an unmasked table") {
- val s = "SELECT a.value1 FROM default.src a union" +
- " (SELECT b.value1 FROM default.unmasked b)"
- checkAnswer("bob", s, Seq(Row(md5Hex("1")), Row("3"), Row("1"), Row("2")))
+ val s = """
+ SELECT value1 from (
+ SELECT a.value1 FROM default.src a
+ union
+ (SELECT b.value1 FROM default.unmasked b)
+ ) c order by value1
+ """
+ checkAnswer("bob", s, Seq(Row("1"), Row("2"), Row("3"), Row(md5Hex("1"))))
}
+
test("union a masked table") {
val s = "SELECT a.value1 FROM default.src a union" +
" (SELECT b.value1 FROM default.src b)"