Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowThe Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.
Hello All,
I have 2 tables, Table 1 is live connection(Using existing dataset) and Table 2 is import file. The Employee ID present in import file should be shown as "Flag - Internal", and for other records should be shown as "External" or "Blank".
We have to bring that Flag column from table 2 to table 1. Using RELATED function we can achieve this but since Table 1 is live connection unable to create Calculate column and Calculate Table.
Using relationship between these 2 table if we directly drag and drop the Flag column in a table visual, data will filtered out where Flag = Internal. Flag = External won'tbe appeared in the visual. I believe it should be handled in Measure.
Please advice how to achieve this measure.
Solved! Go to Solution.
@Arioli_Chezhian Please Try This one.
@Arioli_Chezhian Table 1 is your fact table and Table 2 is the Dimension Table, Right?
@Arioli_Chezhian I hope this helps you. Thank you.
>Create Following Measures :
Tbl1 =
SUM ( 'Table Workspace'[Emp ID] )
#################################
Tbl2 =
SUMX ( 'Table Flag', [Tbl1] )
################################
Flag =
IF ( [Tbl1] = [Tbl2], "Internal", "External" )
@Mahesh0016
I have a correction in the data. You have done SUM for Emp ID, just for example I gave Emp ID as number but in my case the EMP ID has alphabetics with numerics. (Example: abcd324).
In this case we cannot SUM the column right, as the datatype will stay as TEXT.
How to overcome this?
@Arioli_Chezhian I hope this helps you. Thank you.
>Create Following Measures :
Tbl1 =
MAX ( 'Table Workspace'[Emp ID] )
#################################
Tbl2 =
MAXX ( 'Table Flag', [Tbl1] )
################################
Flag =
IF ( [Tbl1] = [Tbl2], "Internal", "External" )
@Arioli_Chezhian okay, I will try and let you know one more thing is your employee ID length is same, right
@Mahesh0016
Yes it's consists of 4 alphabetics continue with 3 numerics (abcd324).
@Mahesh0016 - I tried but when I drag and drop this measure, the visual keeps on loading.
@Mahesh0016 - I am bringing data from Table 1, which contains all the emp ID. Even in Table 1 it has unique records, no duplicates.
@Arioli_Chezhian Please can you Elobrate Table 1 and Table 2 Relationships.
For E.g One To Many, One to One
@Arioli_Chezhian Please Try This one.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
25 | |
12 | |
9 | |
9 | |
9 |
User | Count |
---|---|
19 | |
14 | |
14 | |
13 | |
13 |