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

Extract the last word

Hi Everyone !

I need to extract the last word in a field. Does a function exist to do that ?

Thanks,

11 Replies
prabhu0505
Specialist
Specialist

Solution suggested by Sunny and Colin works fine. Just added another way.

LOAD

subfield(Full_Address, ' ', -1) as LastWord,

Right(Full_Address, len( Full_Address ) -Index(Full_Address,' ', -1)) as LastWord1,

*

INLINE [

Name, Full_Address,

James, 3 rue Victor hugo 60100 CREIL,

Nick, 6 rue Lucien charton 60160 LAIGNEVILLE,

Lena, 9 rue Henri Breuil 60600 CLERMONT,

Jenny, 12 rue des frères grimm 60180 NOGENT

];

Not applicable
Author

Thank You Everyone !