Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

Extra Rank


Hi,

I'd like to add a new rank by the existing data in the script so I can select that data into a Pivot table.

See attacht MS Excel example.

The existing rank contains the data (random and 300 rows): bike, motor, plane, train, walk, run.

The new rank has to be: everything except walk and run must change to transport, walk still be remains the same (walk) and run still be remains the same (run).

I think the best solutions is to make a new rang into the script but maybe there is a better solution.

Thanks in advance.

1 Solution

Accepted Solutions
Not applicable

Re: Extra Rank

Hi

If I understand you correctly, I would recommend that you create a new field to accommodate this data.  Therefore;

Load

     [Mode of Transport],

     If(Match([Mode of Transport], 'Run', 'Walk',)>0, [Mode of Transport], 'Transport') as [Sum. Mode of Transport],

     etc....

From ......

This will give you the flexibility to have either field displayed (or indeed both) and it will not require processing on the front end.

It would be useful to create a Cyclical Group of these two fields, so a user can quickly change between the two should they require a breakdown.

I hope this helps, let me know if I've missed anything.

All the best


Steve

2 Replies
Not applicable

Re: Extra Rank

Hi

If I understand you correctly, I would recommend that you create a new field to accommodate this data.  Therefore;

Load

     [Mode of Transport],

     If(Match([Mode of Transport], 'Run', 'Walk',)>0, [Mode of Transport], 'Transport') as [Sum. Mode of Transport],

     etc....

From ......

This will give you the flexibility to have either field displayed (or indeed both) and it will not require processing on the front end.

It would be useful to create a Cyclical Group of these two fields, so a user can quickly change between the two should they require a breakdown.

I hope this helps, let me know if I've missed anything.

All the best


Steve

Not applicable

Re: Extra Rank

Thanks Steve.

Community Browser