Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Need to capture only Text value in List box

Hi,

          I have a list box which has both "Integer" and "Text" items. I need to capture only "Text" and need to ignore "Integer" from the list. Thanks in advance.

1 Solution

Accepted Solutions
sunny_talwar

Check this:

NULLASVALUE *;

SET NullValue = ' ';

Directory;

LOAD Name,

    Department,

  [Arrival Place],

    [Departure Place],

    [Arrival Time],

    [Departure Time],

    [Total Journey Hours],

    Amount,

    [Booking Date]

FROM

Example1.xlsx

(ooxml, embedded labels, table is Sheet1)

where IsText([Arrival Place]) or Len(Trim([Arrival Place])) = 0;

View solution in original post

12 Replies
tamilarasu
Champion
Champion

You can try below expression,

If(IsText(Left(FieldName,1)), FieldName)

sunny_talwar

May be like this in the script:

Where IsText(FieldName);

or this in the front end list box expression:

If(IsText(FieldName), FieldName)

Anonymous
Not applicable
Author

Something like this?

PurgeChar and KeepChar Functions

Anonymous
Not applicable
Author

Hi Sunny & Tamil,

    Thanks for your help. But once I include the "where" condition in the script, I am getting only "Text" which is correct. But, I am losing my Blank rows. Attached screen shot for your reference. Sry for troubling u.Script Page.jpgFront End.jpg ! !

Anonymous
Not applicable
Author

Hi Balraj,

          Basically I am having Columns with Integer, Text and NULL values. In my front end, I need to capture only Text and NULL values and need to ignore integer values. Above suggestion given by Sunny is working fine, where I am getting only TEXT values but my NULL value (Empty cell) is lost. The link which u shared is different I guess so. Thanks in advance Balraj.

Anonymous
Not applicable
Author

Text left to ignore integer values.jpgHi Tamil,

    Thanks for you Quick reply. I implemented u r formula, But it is duplicating the column values. Attached screen shot for your reference.

sunny_talwar

Try this may be

Where IsText(FieldName) or Len(Trim(FieldName)) = 0;

sunny_talwar

Check this:

NULLASVALUE *;

SET NullValue = ' ';

Directory;

LOAD Name,

    Department,

  [Arrival Place],

    [Departure Place],

    [Arrival Time],

    [Departure Time],

    [Total Journey Hours],

    Amount,

    [Booking Date]

FROM

Example1.xlsx

(ooxml, embedded labels, table is Sheet1)

where IsText([Arrival Place]) or Len(Trim([Arrival Place])) = 0;

Anonymous
Not applicable
Author

Perfect Sunny, Thanks a lot, Checked the above script and working fine.