Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
vsurubotla
New Member

Expand columns after query merge is updating the column values

Hi , I am trying to merge two tables based on ID column. After merge i am expanding the table to get two date columns D1 and D2, which are also there in two tables that i am merging. But after expanding value of the D2 column in first table is getting updated.

 

I tried different ways but unable to find out why the value is getting updated during merge.Its Date/Time type column.

 

 

Thanks,

Vijay.

3 REPLIES 3
BhaveshPatel
Community Champion
Community Champion

Are you using the correct join?? What do you meany by updated D2 column values?

Thanks & Regards,
Bhavesh

Love the Self Service BI.
Please use the 'Mark as answer' link to mark a post that answers your question. If you find a reply helpful, please remember to give Kudos.

Hi,

 

I am using leftouter join. Data of the left table is getting udpated.Please find below my sample data.

 

Table 1:

 

ID(Int)             D1(Date)                   D2(Date)

---------------------------------------------------

1                     9/26/2016               9/28/2016

 

 

Table2:         D1(Date)                   D2(Date)                               

----------------------------------------------------

1                12/26/2016                12/28/2016

 

 

In Merge step data is showing as below :

 

ID(Int)             D1(Date)                   D2(Date)                  NewColumn

---------------------------------------------------------------------------

1                    9/26/2016             9/28/2016                       Table

 

 

After Expand:

 

ID(Int)             D1(Date)                   D2(Date)                  NewColumn.D1       NewColumn.D2

----------------------------------------------------------------------------------------------------

1                   9/26/2016             9/22/2016                   9/22/2016             12/26/2016

 

 

I am not sure whether any formula is getting applied. when i try to verify in the advance filter, I am not seeing any transformation  or formula on these columns. Onething i don't select the common columns D1,D2 during expand i am seeing the D2 column is updating to 9/22/2016 instead of 12/28/2016. 

 

Can you please let me know if there is any way to verify the global level formulas that can be applied on specific columns.

 

Thanks,

Vijay.

 

 

 

Hi @vsurubotla,

 

I merge Table1 and Table2 using leftouter join, and get expected result as follows.

First, select the Id field to match the second table ID field.

1.jpg

 

Click OK, get the following result.

2.png

 

I expand the Table, I get the expected result as the screenshot below. And I post my Power Query statement.

3.png

 

let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMlTSUTIyMDTTt9Q3MkNiWyjFxgIA", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [ID = _t, D1 = _t, D2 = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"ID", Int64.Type}, {"D1", type date}, {"D2", type date}}),
#"Merged Queries" = Table.NestedJoin(#"Changed Type",{"ID"},Table4,{"ID"},"NewColumn",JoinKind.LeftOuter),
#"Expanded NewColumn" = Table.ExpandTableColumn(#"Merged Queries", "NewColumn", {"D1", "D2"}, {"NewColumn.D1", "NewColumn.D2"})
in
#"Expanded NewColumn"



For your issue, I am not able to reproduce your scenario, could you please share your Query for further analysis? Please click “Advanced Editor” in query Editor window and get the Query statement.


Best Regards,
Angelia

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors