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.
Hi all, I have a question for you.
Do you know what the IF statement would be to find a single character from a field to create a new field?
For example: When field A contains 'T' then create field B. The field A is a text field for example T142536, S18273 etc...
I am trying to create a new field if the search criteria = T within field A
- Babinsky
Solved! Go to Solution.
Hi @Babinsky,
Great to hear the problem got resolved! Could you accept the corresponding reply as solution to help others who may have similar issue easily find the answer and close this thread?
Regards
how about using the left function
=if(left(Field A,1)="T",Field A,"")
Thanks for the suggestions but they didn't work. I found the solution if anyone is curious.
SELECT * FROM file
WHERE field1 LIKE 'T%';
That created the new field I wanted that contained the value T.
Okay then!
Did that work for you? I did it in Excel Power Query just to test it. I can do a screen grab in PBI desktop if you want
Yes it did work, Have a great day everyone!
- Babinsky
Hi @Babinsky,
Great to hear the problem got resolved! Could you accept the corresponding reply as solution to help others who may have similar issue easily find the answer and close this thread?
Regards
Done
I'm assuming you want a new COLUMN
Give this a Try
New Column = IF ( ISERROR ( FIND ( "T", Table[Column], 1 ) ), "No there's no T", "Yes there is a T" )
Hope this helps.
Good Luck!
I saw your reply thanks!
New Column = IF ( ISERROR ( FIND ( "T", Table[Column], 1 ) ), "No there's no T", "Yes there is a T" )
Is the following syntax standard? "No there's no T", "Yes there is a T"
It doesn't look like normal coding procedures. I trying to create a new field based on the contents another.
The question was: "Do you know what the IF statement would be to find a single character from a field to create a new field?"
My Normal Coding Procedures do not include reading minds. But you can output whatever you want
Thanks for offering a suggestion. this is getting me closer sorry for not being clear.
What I'm looking to create is for Example - Field1 contains ex: T000 and S000 and I want to create a new field with T000 only.
Not create a Yes or No value.
Do you want a New Column or a New Table?
This will give you the new COLUMN like in my picture above
New Column = IF ( ISERROR ( FIND ( "T", Table[Column], 1 ) ), BLANK(), Table[Column] )
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
63 | |
63 | |
53 | |
39 | |
25 |
User | Count |
---|---|
85 | |
57 | |
45 | |
43 | |
38 |