Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Not applicable

How to get only part of the data from complete column value?

Hi,

I have a table with columns ID, Fullname, Date. How can I get the table only to show values which are under second name

for eg: I have below sample data I need to show table only based on second name

ID    Fullname                           Date

1     Adam Jonesi                     10/03/2012

2     Jony Flait Taypourt           09/10/2000

3     Kaity Gart Marley              21/09/2013

output table should be like below

ID    name              Date

1     Jonesi            10/03/2012

2     Taypourt          09/10/2000

3     Marley            21/09/2013

Please can anyone suggest me in this.

Thanks.

1 Solution

Accepted Solutions
Highlighted

Adding a +1 to the mid function should work:

=Mid(Trim(Fullname), index(Trim(Fullname), ' ', substringcount(Left(Fullname, Index(Fullname, '(')), ' ')-1)+1)

View solution in original post

19 Replies
Highlighted

Hi Amelia, You can try:

Mid(Fullname, Index(Fullname, ' ', -1))

Highlighted

Use this expression:

subfield(Fullname, ' ', substringcount(Fullname, ' ')+1)

let me know

Highlighted
Master III
Master III

Load ID, SubField(Fullname,' ',-1), Date Inline [

ID,Fullname, Date

1, Adam Jonesi,10/03/2012

2, Jony Flait Taypourt,09/10/2000

3, Kaity Gart Marley,21/09/2013 ];

Highlighted
Not applicable

Thanks.

Suppose there is a value Jiou Jane Kiouy (Nee Tunmore) if I want to get like below

Kiouy (Nee Tunmore)

Please suggest

Highlighted

Hi Amelia, my solution works exactly as you desire ....

Highlighted
Not applicable

Thanks.

I used this also but for some values it is showing data as mis match. what I mean is the data is showing for eg if the value is 


Jiou Jane Kiouy (Nee Tunmore)

it is showing as below

Tunmore)

which is not correct

Any help please

Highlighted

Hi Amelia, the expression returns everithing after the last blank spaces, use this to delete all undesidered characters

purgechar(subfield(Fullname, ' ', substringcount(Fullname, ' ')+1),'()')


let me know

Highlighted
Not applicable

Thanks. when I use this it is showing data as

Tunmore

I need the value as Kiouy (Nee Tunmore)

would this possible to get?

Highlighted

It's hardcoded to check also the ( ) name, if there other formats it will fail:

=Mid(Fullname, index(Fullname, ' ', substringcount(Left(Fullname, Index(Fullname, '(')), ' ')-1))