Forum Discussion
Replace (Blank) when Merging Two Tables
Hi,
I have two tables as follows:
Table 1
| Case Id | Case Name |
| 1 | A |
| 2 | B |
| 3 | C |
| 4 | D |
| 5 | E |
| 6 | F |
| 7 | G |
Table 2
| Case Id | Stage |
| 1 | Stage I |
| 2 | Stage I |
| 4 | Stage II |
| 5 | Stage III |
I have created a releationship between these two tables based on "Case Id" and trying to visulaise the number of customers in Table 1 based on stages in Table 2. So, what I want and get for my "Table" visualisation is below:
| Stage | # Cases |
| Stage I | 2 |
| Stage II | 1 |
| Stage III | 1 |
| (Blank) | 3 |
I am now trying to replace the (Blank) in the above visulisation to something else (like "Registered Only"). However, I cannot find a way to do that in Power BI and would be grateful if someone can help me on this please.
Thank you
- Anonymous4 years ago
Hi,
I would recommend doing a full outer join and using this in power query to fill the blanks with what you desire.Column = IF(ISBLANK([Column]),0,[Column)
3 Replies
- Greg_DecklerCommunity Champion
hamadani You will need a disconnected table (no relationships) containing Stage I, Stage II, Stage III and Registered Only as rows. You would then construct a measure to calculate accordingly.
- hamadaniFrequent Visitor
Thanks Greg_Deckler . Do you mean, I need to create a third table with Stage names only? Please note the "Registered Only" is not one of the current stage names in Table 2 and the blanks (which I want to replace its name to Registered Only in my visualisation), only appear after creating a relationship between Table 1 and 2 (which I require that relationship for other purposes too)
- AnonymousNot applicable
Hi,
I would recommend doing a full outer join and using this in power query to fill the blanks with what you desire.Column = IF(ISBLANK([Column]),0,[Column)