Packages

o

org.apache.spark.sql.delta

DeltaTableUtils

object DeltaTableUtils extends PredicateHelper with DeltaLogging

Linear Supertypes
DeltaLogging, DatabricksLogging, DeltaProgressReporter, PredicateHelper, Logging, AliasHelper, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. DeltaTableUtils
  2. DeltaLogging
  3. DatabricksLogging
  4. DeltaProgressReporter
  5. PredicateHelper
  6. Logging
  7. AliasHelper
  8. AnyRef
  9. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def buildBalancedPredicate(expressions: Seq[Expression], op: (Expression, Expression) => Expression): Expression
    Attributes
    protected
    Definition Classes
    PredicateHelper
  6. def canEvaluate(expr: Expression, plan: LogicalPlan): Boolean
    Attributes
    protected
    Definition Classes
    PredicateHelper
  7. def canEvaluateWithinJoin(expr: Expression): Boolean
    Attributes
    protected
    Definition Classes
    PredicateHelper
  8. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  9. def combineWithCatalogMetadata(sparkSession: SparkSession, table: CatalogTable): CatalogTable

    Enrich the metadata received from the catalog on Delta tables with the Delta table metadata.

  10. def containsSubquery(condition: Expression): Boolean

    Check if condition involves a subquery expression.

  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  13. def extractIfPathContainsTimeTravel(session: SparkSession, path: String, options: Map[String, String]): (String, Option[DeltaTimeTravelSpec])

    Check if the given path contains time travel syntax with the @.

    Check if the given path contains time travel syntax with the @. If the path genuinely exists, return None. If the path doesn't exist, but is specifying time travel, return the DeltaTimeTravelSpec as well as the real path.

  14. def extractPredicatesWithinOutputSet(condition: Expression, outputSet: AttributeSet): Option[Expression]
    Attributes
    protected
    Definition Classes
    PredicateHelper
  15. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  16. def findDeltaTableRoot(fs: FileSystem, path: Path): Option[Path]

    Finds the root of a Delta table given a path if it exists.

  17. def findDeltaTableRoot(spark: SparkSession, path: Path, options: Map[String, String] = Map.empty): Option[Path]

    Find the root of a Delta table from the provided path.

  18. def findExpressionAndTrackLineageDown(exp: Expression, plan: LogicalPlan): Option[(Expression, LogicalPlan)]
    Definition Classes
    PredicateHelper
  19. def getAliasMap(exprs: Seq[NamedExpression]): AttributeMap[Alias]
    Attributes
    protected
    Definition Classes
    AliasHelper
  20. def getAliasMap(plan: Aggregate): AttributeMap[Alias]
    Attributes
    protected
    Definition Classes
    AliasHelper
  21. def getAliasMap(plan: Project): AttributeMap[Alias]
    Attributes
    protected
    Definition Classes
    AliasHelper
  22. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  23. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  24. def initializeLogIfNecessary(isInterpreter: Boolean, silent: Boolean): Boolean
    Attributes
    protected
    Definition Classes
    Logging
  25. def initializeLogIfNecessary(isInterpreter: Boolean): Unit
    Attributes
    protected
    Definition Classes
    Logging
  26. def isCatalogTable(catalog: SessionCatalog, tableIdent: TableIdentifier): Boolean

    Checks whether TableIdentifier is a path or a table name We assume it is a path unless the table and database both exist in the catalog

    Checks whether TableIdentifier is a path or a table name We assume it is a path unless the table and database both exist in the catalog

    catalog

    session catalog used to check whether db/table exist

    tableIdent

    the provided table or path

    returns

    true if using table name, false if using path, error otherwise

  27. def isDeltaTable(spark: SparkSession, path: Path): Boolean

    Check if the provided path is the root or the children of a Delta table.

  28. def isDeltaTable(spark: SparkSession, tableName: TableIdentifier): Boolean

    Check whether the provided table name is a Delta table based on information from the Catalog.

  29. def isDeltaTable(table: CatalogTable): Boolean

    Check whether this table is a Delta table based on information from the Catalog.

  30. def isHiddenDirectory(partitionColumnNames: Seq[String], pathName: String): Boolean

    Whether a path should be hidden for delta-related file operations, such as Vacuum and Fsck.

  31. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  32. def isNullIntolerant(expr: Expression): Boolean
    Attributes
    protected
    Definition Classes
    PredicateHelper
  33. def isPredicateMetadataOnly(condition: Expression, partitionColumns: Seq[String], spark: SparkSession): Boolean

    Check if condition can be evaluated using only metadata.

    Check if condition can be evaluated using only metadata. In Delta, this means the condition only references partition columns and involves no subquery.

  34. def isPredicatePartitionColumnsOnly(condition: Expression, partitionColumns: Seq[String], spark: SparkSession): Boolean

    Does the predicate only contains partition columns?

  35. def isTraceEnabled(): Boolean
    Attributes
    protected
    Definition Classes
    Logging
  36. def isValidPath(tableIdent: TableIdentifier): Boolean

    tableIdent

    the provided table or path

    returns

    whether or not the provided TableIdentifier can specify a path for parquet or delta

  37. def log: Logger
    Attributes
    protected
    Definition Classes
    Logging
  38. def logConsole(line: String): Unit
    Definition Classes
    DatabricksLogging
  39. def logDebug(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  40. def logDebug(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  41. def logError(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  42. def logError(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  43. def logInfo(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  44. def logInfo(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  45. def logName: String
    Attributes
    protected
    Definition Classes
    Logging
  46. def logTrace(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  47. def logTrace(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  48. def logWarning(msg: => String, throwable: Throwable): Unit
    Attributes
    protected
    Definition Classes
    Logging
  49. def logWarning(msg: => String): Unit
    Attributes
    protected
    Definition Classes
    Logging
  50. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  51. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  52. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  53. def outputWithNullability(output: Seq[Attribute], nonNullAttrExprIds: Seq[ExprId]): Seq[Attribute]
    Attributes
    protected
    Definition Classes
    PredicateHelper
  54. def parseColToTransform(col: String): IdentityTransform
  55. def recordDeltaEvent(deltaLog: DeltaLog, opType: String, tags: Map[TagDefinition, String] = Map.empty, data: AnyRef = null, path: Option[Path] = None): Unit

    Used to record the occurrence of a single event or report detailed, operation specific statistics.

    Used to record the occurrence of a single event or report detailed, operation specific statistics.

    path

    Used to log the path of the delta table when deltaLog is null.

    Attributes
    protected
    Definition Classes
    DeltaLogging
  56. def recordDeltaOperation[A](deltaLog: DeltaLog, opType: String, tags: Map[TagDefinition, String] = Map.empty)(thunk: => A): A

    Used to report the duration as well as the success or failure of an operation on a deltaLog.

    Used to report the duration as well as the success or failure of an operation on a deltaLog.

    Attributes
    protected
    Definition Classes
    DeltaLogging
  57. def recordDeltaOperationForTablePath[A](tablePath: String, opType: String, tags: Map[TagDefinition, String] = Map.empty)(thunk: => A): A

    Used to report the duration as well as the success or failure of an operation on a tahoePath.

    Used to report the duration as well as the success or failure of an operation on a tahoePath.

    Attributes
    protected
    Definition Classes
    DeltaLogging
  58. def recordEvent(metric: MetricDefinition, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, trimBlob: Boolean = true): Unit
    Definition Classes
    DatabricksLogging
  59. def recordFrameProfile[T](group: String, name: String)(thunk: => T): T
    Attributes
    protected
    Definition Classes
    DeltaLogging
  60. def recordOperation[S](opType: OpType, opTarget: String = null, extraTags: Map[TagDefinition, String], isSynchronous: Boolean = true, alwaysRecordStats: Boolean = false, allowAuthTags: Boolean = false, killJvmIfStuck: Boolean = false, outputMetric: MetricDefinition = null, silent: Boolean = true)(thunk: => S): S
    Definition Classes
    DatabricksLogging
  61. def recordProductEvent(metric: MetricDefinition with CentralizableMetric, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, trimBlob: Boolean = true): Unit
    Definition Classes
    DatabricksLogging
  62. def recordProductUsage(metric: MetricDefinition with CentralizableMetric, quantity: Double, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, forceSample: Boolean = false, trimBlob: Boolean = true, silent: Boolean = false): Unit
    Definition Classes
    DatabricksLogging
  63. def recordUsage(metric: MetricDefinition, quantity: Double, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, forceSample: Boolean = false, trimBlob: Boolean = true, silent: Boolean = false): Unit
    Definition Classes
    DatabricksLogging
  64. def replaceAlias(expr: Expression, aliasMap: AttributeMap[Alias]): Expression
    Attributes
    protected
    Definition Classes
    AliasHelper
  65. def replaceAliasButKeepName(expr: NamedExpression, aliasMap: AttributeMap[Alias]): NamedExpression
    Attributes
    protected
    Definition Classes
    AliasHelper
  66. def replaceFileFormat(target: LogicalPlan, updatedFileFormat: FileFormat): LogicalPlan

    Update FileFormat for a plan and return the updated plan

    Update FileFormat for a plan and return the updated plan

    target

    Target plan to update

    updatedFileFormat

    Updated file format

    returns

    Updated logical plan

  67. def replaceFileIndex(target: LogicalPlan, fileIndex: FileIndex): LogicalPlan

    Replace the file index in a logical plan and return the updated plan.

    Replace the file index in a logical plan and return the updated plan. It's a common pattern that, in Delta commands, we use data skipping to determine a subset of files that can be affected by the command, so we replace the whole-table file index in the original logical plan with a new index of potentially affected files, while everything else in the original plan, e.g., resolved references, remain unchanged.

    target

    the logical plan in which we replace the file index

    fileIndex

    the new file index

  68. def resolveTimeTravelVersion(conf: SQLConf, deltaLog: DeltaLog, tt: DeltaTimeTravelSpec, canReturnLastCommit: Boolean = false): (Long, String)

    Given a time travel node, resolve which version it is corresponding to for the given table and return the resolved version as well as the access type, i.e.

    Given a time travel node, resolve which version it is corresponding to for the given table and return the resolved version as well as the access type, i.e. by version or timestamp.

  69. def splitConjunctivePredicates(condition: Expression): Seq[Expression]
    Attributes
    protected
    Definition Classes
    PredicateHelper
  70. def splitDisjunctivePredicates(condition: Expression): Seq[Expression]
    Attributes
    protected
    Definition Classes
    PredicateHelper
  71. def splitMetadataAndDataPredicates(condition: Expression, partitionColumns: Seq[String], spark: SparkSession): (Seq[Expression], Seq[Expression])

    Partition the given condition into two sequence of conjunctive predicates: - predicates that can be evaluated using metadata only.

    Partition the given condition into two sequence of conjunctive predicates: - predicates that can be evaluated using metadata only. - other predicates.

  72. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  73. def toString(): String
    Definition Classes
    AnyRef → Any
  74. def trimAliases(e: Expression): Expression
    Attributes
    protected
    Definition Classes
    AliasHelper
  75. def trimNonTopLevelAliases[T <: Expression](e: T): T
    Attributes
    protected
    Definition Classes
    AliasHelper
  76. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  77. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  78. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  79. def withDmqTag[T](thunk: => T): T
    Attributes
    protected
    Definition Classes
    DeltaLogging
  80. def withStatusCode[T](statusCode: String, defaultMessage: String, data: Map[String, Any] = Map.empty)(body: => T): T

    Report a log to indicate some command is running.

    Report a log to indicate some command is running.

    Definition Classes
    DeltaProgressReporter

Inherited from DeltaLogging

Inherited from DatabricksLogging

Inherited from DeltaProgressReporter

Inherited from PredicateHelper

Inherited from Logging

Inherited from AliasHelper

Inherited from AnyRef

Inherited from Any

Ungrouped