Github user xuanyuanking commented on a diff in the pull request: https://github.com/apache/spark/pull/21775#discussion_r202703948 --- Diff: sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveDDLSuite.scala --- @@ -2248,4 +2249,20 @@ class HiveDDLSuite checkAnswer(spark.table("t4"), Row(0, 0)) } } + + test("desc formatted table for last access verification") { + withTable("t1") { + sql(s"create table" + + s" if not exists t1 (c1_int int, c2_string string, c3_float float)") + val desc = sql("DESC FORMATTED t1").collect().toSeq + val lastAcessField = desc.filter((r: Row) => r.getValuesMap(Seq("col_name")) + .get("col_name").getOrElse("").equals("Last Access")) + // Check whether lastAcessField key is exist + assert(!lastAcessField.isEmpty) + val validLastAcessFieldValue = lastAcessField.filterNot((r: Row) => ((r --- End diff -- where is the val `validLastAcessFieldValue` used?
--- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org