• Skip to main content
  • Skip to footer

Curbal

Learn how to grow your business with your data and Power BI

  • Data Stories
    • Power BI Stories
    • 1 dataset, 100 matplotlib visualizations
  • Learning Portal
    • Download Center
    • 25 Days Challenge
    • DAX Glossary
    • Power BI
    • Power BI by Topic
    • Python
    • 1 dataset, 100 matplotlib visualizations
  • Courses
    • Power BI Mini Master Class 1: Using a REST API as a data source
    • Power BI Master Class 1: COVID Tracker
    • Introduction to Power BI – FREE Online course
    • M Language + Power Query Course Bundle
    • Power Query Online Training [updated 2022]
    • M Language Online Course: The unofficial and Practical Reference Guide [updated 2025]
    • My Courses
  • Shop
    • Courses
    • Master Classes
    • Template Apps
    • JSON Themes
  • Cart
  • Register/ Log In
    • Become a Member
    • Log In
    • My account
    • My Courses
  • Search
  • Contact
You are here: Home / CM Tooltip Glossary Pro+ / UNION

UNION

posted on October 19, 2017

« Back to Glossary Index

Syntax

UNION(<table_expression1>, <table_expression2> [,<table_expression>]…)  

PART1: Tutorial with example

In today’s DAX Fridays! video we will go through the DAX function UNION. UNION function will append two tables using DAX language.

DAX Fridays! #36: UNION

Part 2:

Let me start by saying: “you shouldn’t do it in DAX”, but if you still have to do it, in this video I will show you how to unpivot tables with DAX. I will then unpivot them using Power Query so you can see the difference, and how Power Query can be faster and more efficient for cleaning data.

DAX Fridays! #113: Unpivot tables with DAX

Download example file:

Link to Power BI file: here.

Remarks

The two tables must have the same number of columns.

Columns are combined by position in their respective tables.

The column names in the return table will match the column names in table_expression1.

Duplicate rows are retained.

The returned table has lineage where possible. For example, if the first column of each table_expression has lineage to the same base column C1 in the model, the first column in the UNION result will have lineage to C1. However, if combined columns have lineage to different base columns, or if there is an extension column, the resulting column in UNION will have no lineage.

When data types differ, the resulting data type is determined based on the rules for data type coercion.

The returned table will not contain columns from related tables.

Was this helpful?
See Also:
  • ROW
« Back to Index

Reader Interactions

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Footer CTA

Join our community of +50,000 professionals

Become a Member

Subscribe to YouTube

About me:

Curbal AB
Badhusgatan 7B
722 15 – Västerås
Sweden

OrgNo: 5569680852 | VAT: SE556968085201

 

Location:

© Copyright 2014-2025 · Curbal AB · All Rights Reserved · Privacy Policy · Terms of Service · Refund Policy · Log In