Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Left/Right Function

Hi All

Is there a function in Qlikview equivalent to SQL Left and Right function.

I have a "~" separator and would like to get values to the left of it.

1~08-24 should return 1

125~feb 28 should return 125

1 Solution

Accepted Solutions
Gysbert_Wassenaar

You can use the subfield for this with ~ as field separator. subfield('1~08~24', '~', 1) will return 1


talk is cheap, supply exceeds demand

View solution in original post

5 Replies
Gysbert_Wassenaar

You can use the subfield for this with ~ as field separator. subfield('1~08~24', '~', 1) will return 1


talk is cheap, supply exceeds demand
robert_mika
Master III
Master III

Another Way

=TextBetween('~'&'125~feb 28','~','~')

Not applicable
Author

Hi,

You can use subfield as Gysberts said / you can use Left() like this

Left(Fieldname, Index(Fieldname, '~')-1) as FieldName

Anonymous
Not applicable
Author

I often use the QV mid() function as simpler alternative to the QV left() and right() functions.

Not applicable
Author

Thanks a lot guys for the solution