Union Tool

Combine two or more data streams with similar structures based on column names or positions. The tool accepts multiple inputs based on either column name or record position, creating a stacked output table. You can then configure how these columns stack or match up. In the output, each column will contain the data from each input.

Visit the Alteryx Community Tool Mastery series to learn even more about the Union Tool.

Configure the tool

  1. Mode: Choose the preferred configuration mode. The default setting is Auto configure by name.
    • Auto configure by name: Align columns by column name.
    • Auto configure by position: Align columns by their column order in the stream.
    • Manually configure columns: Allows you to manually align the inputs. When you choose this method, the columns in each input are displayed (indicated by row #1, #2, etc.).
    • Configuration at runtime

      When the mode is set to Manually configure columns, Alteryx assumes the configuration will not change at runtime. Therefore, if anything is missing, an error occurs. Do not use this configuration mode in Analytic Apps and Macros.

    1. When columns differ: When either auto configuration mode is selected, you must select how to handle nonconforming data columns and an output option.
    2. Error handling choices include:

      • Error - stop processing records: Will throw an error in the Results window, and end the schema.
      • Warning - continue processing records: Throw a warning in the Results window, but still run the schema.
      • Ignore - continue processing records: Ignore nonconforming data columns and run the schema.

      Output options:

      • Output all columns: All columns are included. Null values populate empty columns.
      • Output common subset of columns: Only the columns that each input have in common are outputted.
    3. When the Manually configure columns mode is chosen, you can:
      • Click Order by to order columns by Matching column names or Original column position.
      • Click inside a column and then click the arrows to manually set the column position.
      • Select Immediately pass data rows downstream without waiting for all inputs to send data. Do not use this mode if the upstream metainfo will change between configuration time and runtime.
      • Change in default behavior

        This option is selected by default for workflows developed prior to Alteryx 10.1.

  2. Output order: You can select Specify order of union and then drag the column names to arrange the order of the union. This option is available for all configuration modes, but can cause slower performance.