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
Specialist
Specialist

Combining codes together & present the value adding both MO & NM

Dear Friends

If I am to combine both codes define for MO & NM together & to present value adding both, how it is done both at script level & front end. Also if the serial of the codes end with 1 such as 171,191 etc, I need to give a function to pick all codes ends with 1 as Motor Codes. Also this should be only from  seventy code series such as 77151,

Thanks in advance

1 Solution

Accepted Solutions
Highlighted
Specialist
Specialist

Script:

LOAD
*,
SubField(TYPE, '-',1) as Combined_Type,
IF(Left(CODE,1)=7, IF(Right(CODE,1)=1, 'Yes','No'),'No') as Motor_Code;
LOAD TYPE, CODE, VALUE
FROM (ooxml, embedded labels, table is Sheet1);

UI:

Combined Type Dimension: Text(Trim(SubField(TYPE, '-',1)))

Motor Code Dimension: IF(Left(CODE,1)=7,IF(Right(CODE,1)=1,'Yes', 'No'),'No')

You can create the same dimensions as columns in the script.

View solution in original post

6 Replies
Highlighted
Specialist
Specialist

Refer the attachment

Highlighted
Specialist
Specialist

Please find the attached and let me know if it matches your requirement.

Highlighted
Specialist
Specialist

Created two more charts for visualizations.

PFA.

Highlighted
Specialist
Specialist

Hi Vamsee

Sorry for the delay in response as I was away from home. Could you please send me your working typed in the body of the reply the fact is that I cannot open your answer. I am using a personnel edition of qlik view.

Thanks

Neville

Highlighted
Specialist
Specialist

Script:

LOAD
*,
SubField(TYPE, '-',1) as Combined_Type,
IF(Left(CODE,1)=7, IF(Right(CODE,1)=1, 'Yes','No'),'No') as Motor_Code;
LOAD TYPE, CODE, VALUE
FROM (ooxml, embedded labels, table is Sheet1);

UI:

Combined Type Dimension: Text(Trim(SubField(TYPE, '-',1)))

Motor Code Dimension: IF(Left(CODE,1)=7,IF(Right(CODE,1)=1,'Yes', 'No'),'No')

You can create the same dimensions as columns in the script.

View solution in original post

Highlighted
Specialist
Specialist

Thanks Vamsee,

This is what I needed

Neville