Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi there,
Having a following table
| Code | Group | Color | Hue |
| 101 | PT-15 | Green | Blue |
| 102 | PT-14 | Yellow | Red |
| 103 | CC-11 | Dark | |
| 104 | BA-10 | Black |
I would like to add another column who works as follows:
Return values from column Color BUT if Group starts with PT return values from colum Hue for these rows.
Is it possible please
Solved! Go to Solution.
Thanks for your help, but it doesn't work.
I did find this working :
DAX Column = IF (CONTAINSSTRING('Table'[String], "TRA"), "TRA" ,BLANK())
try this:
Thumb for help, but yes I solve my problem after finding code . Still thanks for your post
DAX Column = IF (CONTAINSSTRING('Table'[String], "TRA"), "TRA" ,BLANK()).
Thanks for your help, but it doesn't work.
I did find this working :
DAX Column = IF (CONTAINSSTRING('Table'[String], "TRA"), "TRA" ,BLANK())
Hi @MasterSonic
Try below DAX
= If( Left(table[Group],2) = "PT",[Hue],[color])
If this post helps, then please consider Accept it as the solution, Appreciate your Kudos!!
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
Check out the November 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 19 | |
| 11 | |
| 9 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 35 | |
| 32 | |
| 20 | |
| 12 | |
| 10 |