Class DeltaMergeMatchedActionBuilder


  • public class DeltaMergeMatchedActionBuilder
    extends Object
    Builder class to specify the actions to perform when a target table row has matched a source row based on the given merge condition and optional match condition.

    See DeltaMergeBuilder for more information.

    Since:
    0.3.0
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      DeltaMergeBuilder delete()
      Delete a matched row from the table.
      DeltaMergeBuilder update​(java.util.Map<String,​org.apache.spark.sql.Column> set)
      Update a matched table row based on the rules defined by set.
      DeltaMergeBuilder update​(scala.collection.Map<String,​org.apache.spark.sql.Column> set)
      Update the matched table rows based on the rules defined by set.
      DeltaMergeBuilder updateAll()
      Update all the columns of the matched table row with the values of the corresponding columns in the source row.
      DeltaMergeBuilder updateExpr​(java.util.Map<String,​String> set)
      Update a matched table row based on the rules defined by set.
      DeltaMergeBuilder updateExpr​(scala.collection.Map<String,​String> set)
      Update the matched table rows based on the rules defined by set.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DeltaMergeMatchedActionBuilder

        public DeltaMergeMatchedActionBuilder()
    • Method Detail

      • update

        public DeltaMergeBuilder update​(scala.collection.Map<String,​org.apache.spark.sql.Column> set)
        Update the matched table rows based on the rules defined by set.

        Parameters:
        set - rules to update a row as a Scala map between target column names and corresponding update expressions as Column objects.
        Since:
        0.3.0
      • updateExpr

        public DeltaMergeBuilder updateExpr​(scala.collection.Map<String,​String> set)
        Update the matched table rows based on the rules defined by set.

        Parameters:
        set - rules to update a row as a Scala map between target column names and corresponding update expressions as SQL formatted strings.
        Since:
        0.3.0
      • update

        public DeltaMergeBuilder update​(java.util.Map<String,​org.apache.spark.sql.Column> set)
        Update a matched table row based on the rules defined by set.

        Parameters:
        set - rules to update a row as a Java map between target column names and corresponding expressions as Column objects.
        Since:
        0.3.0
      • updateExpr

        public DeltaMergeBuilder updateExpr​(java.util.Map<String,​String> set)
        Update a matched table row based on the rules defined by set.

        Parameters:
        set - rules to update a row as a Java map between target column names and corresponding expressions as SQL formatted strings.
        Since:
        0.3.0
      • updateAll

        public DeltaMergeBuilder updateAll()
        Update all the columns of the matched table row with the values of the corresponding columns in the source row.
        Since:
        0.3.0
      • delete

        public DeltaMergeBuilder delete()
        Delete a matched row from the table.
        Since:
        0.3.0