Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
Here is another alternate
Alternate_Before_2nd_Delimiter = 
VAR FirstHyphen = IFERROR(FIND("-", 'Data'[Column], 1), 0)
VAR SecondHyphen = IFERROR(FIND("-", 'Data'[Column], FirstHyphen + 1), 0)
RETURN 
    SWITCH(
        TRUE(),
        SecondHyphen = 0, 'Data'[Column],  
        LEFT('Data'[Column], SecondHyphen - 1)
    )
					
				
			
			
				
			
			
				
			
			
				
			
			
			
			
			
		Hi @Anonymous 
Could you please try below Calculated Column :
Extract_Before_2ndDash =
VAR InputText = 'Table'[Column Name]
VAR FirstDash = SEARCH("-", InputText, 1)
VAR SecondDash = SEARCH("-", InputText, FirstDash + 1)
RETURN
    LEFT(InputText, SecondDash - 1)
maybe this doesn't find blank value? still got error.
VAR InputText = 'Table'[Column Name]
VAR FirstDash = SEARCH("-", InputText, 1)
VAR SecondDash = SEARCH("-", InputText, FirstDash + 1)
RETURN
    LEFT(InputText, SecondDash - 1)
HI @Anonymous you can try this
Before_2nd_Delimiter = 
VAR ModifiedString = SUBSTITUTE(Data[Column], "-", "|", 2)
VAR SecondDelimiterPos = FIND("|", ModifiedString, 1)
RETURN 
    IF(
        ISERROR(SecondDelimiterPos),
        Data[Column],
        LEFT(Data[Column], SecondDelimiterPos - 1)
    )Results:
Find this helpful? ✔ Give a Kudo • Mark as Solution – help others too!
Hi,
Got error this
Here is another alternate
Alternate_Before_2nd_Delimiter = 
VAR FirstHyphen = IFERROR(FIND("-", 'Data'[Column], 1), 0)
VAR SecondHyphen = IFERROR(FIND("-", 'Data'[Column], FirstHyphen + 1), 0)
RETURN 
    SWITCH(
        TRUE(),
        SecondHyphen = 0, 'Data'[Column],  
        LEFT('Data'[Column], SecondHyphen - 1)
    )
					
				
			
			
				
			
			
				
			
			
			
			
			
			
		Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.