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 Friends,
I want to get specific values from the existing column to new column .Is it possible with like or search condition in Dax.
Let's say in the below table i want only *Target values from the Name column like Target Values column as mentioned .
Name Value Target values
A Metric 1
B Target 1 B Target
C Target 1 C Target'
C Metric 1
AA Metric 1
AA Target 1 AA Target
DD 1
FF 1
G Target 1 G Target
If it's possible kindly let me know.
Thanks in advance
Solved! Go to Solution.
As a Calc Column, try this
=if(search("Target",[Name],1,0)>0,[Name])
Hi Harib,
I would suggest the easiest way to do this is in the query editor rather than DAX. But the post below has a solution that explains how to do it in both:
Hope that helps!
Matt
@harib depends on what you trying to do, you can do stuff in dax and power query
in dax there is
or a simple new column;
https://docs.microsoft.com/en-us/dax/search-function-dax
https://docs.microsoft.com/en-us/dax/find-function-dax
these just find po
they return the position of what you looking for...
what would be the condition of the copy?
also fairly simple to do in power query in a conditional or custom column, why would you do it in dax? is it for the user to do something or is it part of your data transformations?
Proud to be a Super User!
As a Calc Column, try this
=if(search("Target",[Name],1,0)>0,[Name])
Hi, I have two Data sets as below.
Table 1:
Product | YTD1 | YTD2 | YTD3 | Total |
A | 10 | 15 | 12 | 37 |
B | 5 | 2 | 1 | 8 |
C | 6 | 1 | 3 | 10 |
Total | 55 |
Table 2:
Month | YTD |
Jan | YTD1 |
Feb | YTD2 |
Mar | YTD3 |
I want to create a NewColumn (or maybe a new measure) in Table 1 which is dependent on a Slicer (value: Jan, Feb, Mar) in the Report.
For example, if filtered value is "Jan" in the slicer, the NewColumn will get YTD1 column, if "Feb", then it will get YTD2 column.
What is the way to do this?
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
73 | |
72 | |
38 | |
30 | |
26 |
User | Count |
---|---|
99 | |
87 | |
45 | |
43 | |
35 |