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.
Scenario:
Creating a new column using a DAX formula. The formula is not creating the output I need.
My Experience Level:
2 Years PowerBI
3 Months DAX
Locations Table
Site# Name Type
1 Test Site CBOC ???? (New Column) Derived from formula below
2 Test Site Clinic
3 Test Site Resource
Formula
SWITCH(
TRUE(),
CONTAINSSTRING(VALocations[Name]="CBOC"),"CBOC",
"TBD"
)
My current output
Site# Name Type
1 Test Site CBOC TBD
2 Test Site Clinic TBD
3 Test Site Resource TBD
Solved! Go to Solution.
Hi @dkcheney
pay attention to CONTAINSSTRING syntax: https://docs.microsoft.com/en-us/dax/containsstring-function-dax
use comma
CONTAINSSTRING(VALocations[Name], "CBOC")
Hi @dkcheney
pay attention to CONTAINSSTRING syntax: https://docs.microsoft.com/en-us/dax/containsstring-function-dax
use comma
CONTAINSSTRING(VALocations[Name], "CBOC")
User | Count |
---|---|
22 | |
11 | |
8 | |
6 | |
6 |
User | Count |
---|---|
25 | |
13 | |
11 | |
9 | |
6 |