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.
Hello,
I'm trying to create a calculated column with two conditions on IF.
First criteria: If column1 contains "rtb+"
Second criteria: if column2 doesn't contain "Deals_"
#"RTB+ Impressions_clm" =
Table.AddColumn(Hb_Impressions_clm, "RTB+ Impressions", each if (Text.Contains([#"Column1"], "RTB+")
and (not Text.Contains([#"Column2"], "Deals_")))
then [Impressions]
else null)
What i'm doing wrong?
Thank you,
Grigoris
Solved! Go to Solution.
@polman4 , seem fine
if (Text.Contains([#"Column1"], "RTB+") and ( not Text.Contains([#"Column2"], "Deals_"))
then [Impressions]
else null
but it is case sensitive , you can use Text.Upper, example
if (Text.Contains(Text.Upper([#"Column1"]), "RTB+") and ( not Text.Contains([#"Column2"], "Deals_"))
then [Impressions]
else null
@polman4 , seem fine
if (Text.Contains([#"Column1"], "RTB+") and ( not Text.Contains([#"Column2"], "Deals_"))
then [Impressions]
else null
but it is case sensitive , you can use Text.Upper, example
if (Text.Contains(Text.Upper([#"Column1"]), "RTB+") and ( not Text.Contains([#"Column2"], "Deals_"))
then [Impressions]
else null
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
75 | |
71 | |
38 | |
29 | |
26 |
User | Count |
---|---|
97 | |
96 | |
60 | |
44 | |
41 |