multiTableRepartitionDS#

swordfish.function.multiTableRepartitionDS()#

Generate a tuple of data sources from multiple tables with a new partitioning design.

If query is metacode of SQL statements, the parameter column must be specified. partitionType and partitionScheme can be unspecified for a partitioned table with a COMPO domain. In this case, the data sources will be determined based on the original partitionType and partitionScheme of column.

If query is a tuple of metacode of SQL statements, column, partitionType and partitionScheme should be unspecified. The function returns a tuple with the same length as query. Each element of the result is a data source corresponding to a piece of metacode in query.

Parameters:
  • query (Constant) – Metacode of SQL statements or a tuple of metacode of SQL statements.

  • column (Constant) – A string indicating a column name in query. Function multiTableRepartitionDS deliminates data sources based on column.

  • partitionType (Constant) – The type of partition. It can take the value of VALUE or RANGE.

  • partitionScheme (Constant) – A vector indicating the partitioning scheme. For details please refer to DistributedComputing.

  • local (Constant) – A Boolean value indicating whether to move the data sources to the local node for computing. The default value is true.