Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Table 1: Register for Grade - It keeps all the grade IDs and Model Names/ Family
Table 2: Register for Grade Issues - It keeps all the issues of the Models
Help! I want to create a column named “Tracking Column” in Table 2. What codes / measures / conditions should I use?
IF Model Name/Family in Table 2 has a Family according to Table 1 - Family Column, then ‘Tracking Column’ in Table 2 will reflect the Model Family Name. In this instance, Credit 3 Model in Table 2 belongs to Credit Family Model. Tracking column will pick up its Family from Table 1 – Model Family column and list Credit family Model in Tracking column.
IF Model Name /Family in Table 2 has no family name according to Table 1 i.e. N/A, then tracking column will only reflect the Model Name in Model Name/Family in Table 2. Example, Frequency Check Model.
Hope it makes sense!
Solved! Go to Solution.
Hi @TTPP81 To acheive the Tracking column according to your condition, follow the steps mentionded below:
Considering you have both the tables in power query, if not bring them in power query.
1. Open power query and click merge queries. See images below (Red Highlighted):
2. You will ge the below window, select Model Name/Family column from Table2 in upper table and Model Name From Table1 in lower table. Click Ok. See Image below:
3. Click double arrow head Icon in Table1 column and expand only Family column from Table1. See image below:
You will get below screen:
4. Create a custom conditional column. Codition would be:
If [Family] = null then [Model Name/Family] else if [Family] = N/A then [Model Name/Family] else [Family]
See images below:
After click ok, you will get your desired result. Remove Family Column. See the output below, as your requirement:
Hope this helps!!
If this solved your problem, please accept it as a solution!!
Best Regards,
Shahariar Hafiz
Please provide the data in type table
Hi @TTPP81 To acheive the Tracking column according to your condition, follow the steps mentionded below:
Considering you have both the tables in power query, if not bring them in power query.
1. Open power query and click merge queries. See images below (Red Highlighted):
2. You will ge the below window, select Model Name/Family column from Table2 in upper table and Model Name From Table1 in lower table. Click Ok. See Image below:
3. Click double arrow head Icon in Table1 column and expand only Family column from Table1. See image below:
You will get below screen:
4. Create a custom conditional column. Codition would be:
If [Family] = null then [Model Name/Family] else if [Family] = N/A then [Model Name/Family] else [Family]
See images below:
After click ok, you will get your desired result. Remove Family Column. See the output below, as your requirement:
Hope this helps!!
If this solved your problem, please accept it as a solution!!
Best Regards,
Shahariar Hafiz
Thank you, it worked. Appreciate your help