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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
KatkaS
Post Patron
Post Patron

Not returning the value..

Hello,

I'm wondering if someone could help me with following..

 

I created new column in Data tab to return a value from another excel sheet, but the values are not returned...

No error is indicated.

 

Could anyone try to help me to understand what the issue could be?

 

Thank you!

 

New column.jpg

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

It seems like coming from the same sheet not different. and You compared [FAM], which I do not see in this table.

 

This how we get from another table

New Column = sumx(filter(table2,table2[Col1]= table1[col1] && table2[Col2]= table1[col2] ),table2[required_col])

 

same table

New Column = maxx(filter(table1,table1[Col1]= earlier(table1[col1]) && table1[Col1]= earlier(table1[col2]) ),table1[required_col])

 

Condition can change as per need

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

5 REPLIES 5
v-gizhi-msft
Community Support
Community Support

Hi,

 

After my test, it works well here:

Amount of ESC = CALCULATE(SUM(ECS[Amount]),FILTER(ECS,ECS[FAM]=EARLIER(BW[Operational Company])&&ECS[FAM LINE]=EARLIER(BW[FAM Line])&&ECS[Period]=BW[Period]))

60.PNG

Here is my test pbix file:

pbix 

Please check it.

Hope this helps.

 

Best Regards,

Giotto Zhi

amitchandak
Super User
Super User

It seems like coming from the same sheet not different. and You compared [FAM], which I do not see in this table.

 

This how we get from another table

New Column = sumx(filter(table2,table2[Col1]= table1[col1] && table2[Col2]= table1[col2] ),table2[required_col])

 

same table

New Column = maxx(filter(table1,table1[Col1]= earlier(table1[col1]) && table1[Col1]= earlier(table1[col2]) ),table1[required_col])

 

Condition can change as per need

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thank you, Amit!!! I had to add another condition for Period, but the logic you desribed worked very well.

az38
Community Champion
Community Champion

Hi @KatkaS 

try to use ALL() inside filter, like FILTER(ALL('2_Diff_Esc Data'), '2_Diff_Esc Data'[FAM Line]=...)


do not hesitate to give a kudo to useful posts and mark solutions as solution
LinkedIn
Mariusz
Community Champion
Community Champion

Hi @KatkaS 

 

Sure, can you explain what you would like to do, what is the relationship between these tables and if the table you are adding the column to is on one side of this relationship or on the many side?

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
LinkedIn

 

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

July Power BI Update Carousel

Power BI Monthly Update - July 2026

Check out the July 2026 Power BI update to learn about new features.

60 days of Data Days Carousel

Data Days 2026

Join Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Solution Authors