Github user wzhfy commented on a diff in the pull request:
https://github.com/apache/spark/pull/16323#discussion_r93740553
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/catalog/interface.scala
---
@@ -237,6 +239,38 @@ case class CatalogTable(
}
+/**
+ * This class of statistics is used in [[CatalogTable]] to interact with
metastore.
+ */
+case class CatalogStatistics(
+ sizeInBytes: BigInt,
+ rowCount: Option[BigInt] = None,
+ colStats: Map[String, ColumnStat] = Map.empty) {
+
+ /**
+ * Convert [[CatalogStatistics]] to [[Statistics]], and match column
stats to attributes based
+ * on column names.
+ */
+ def convert(attributes: Seq[Attribute]): Statistics = {
--- End diff --
That's a lot better, thanks!
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]