Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Change values from the script (if, case statement)


Hello Qlikviewers,

I have got the following table:

DimTimeMonthly:
LOAD
Mid(MonthName,1,3) as Month

FROM
$(vPath_Reference_Data)DimTimeMonthly.qvd
(
qvd)

;

Feb
Month
Jan
Mar
Apr

I was asked to introduce a slider in the QVW the months in spanish:

ENE... Feb.. Mar.... ABR

How can I change the values of the field from the script???

Thanks!!!

1 Solution

Accepted Solutions
Not applicable
Author

Marcus and Ioannis,

Thank you for your help...

I figure other way to do it:

In the slide, in stead of choosing the field, i made an expression

=If(Month='Jan','Ene',
if(Month='Feb','Feb',
if(Month='Mar','Mar',
if(Month='Apr','Abr',
if(Month='May','May',
if(Month='Jun','Jun',
if(Month='Jul','Jul',
if(Month='Aug','Ago',
if(Month='Sep','Sep',
if(Month='Oct','Oct',
if(Month='Nov','Nov',
'Dec'
)
)
)))))))))

It was a bit too much but it solved the problem.


View solution in original post

3 Replies
giakoum
Partner - Master II
Partner - Master II

There is a set command for that :

SET MonthNames='Jan;Feb;Mar;Apr;May;Jun;Jul;Aug;Sep;Oct;Nov;Dec';

Change them to Spanish

marcus_sommer

If you don't want to be set the spanish values as default - have a look here: http://community.qlik.com/blogs/qlikviewdesignblog/2012/11/30/handling-multiple-languages

If you it only need at a few points an approach with pick(match('Jan', ...), 'ENE', ...) could be easier.

- Marcus

Not applicable
Author

Marcus and Ioannis,

Thank you for your help...

I figure other way to do it:

In the slide, in stead of choosing the field, i made an expression

=If(Month='Jan','Ene',
if(Month='Feb','Feb',
if(Month='Mar','Mar',
if(Month='Apr','Abr',
if(Month='May','May',
if(Month='Jun','Jun',
if(Month='Jul','Jul',
if(Month='Aug','Ago',
if(Month='Sep','Sep',
if(Month='Oct','Oct',
if(Month='Nov','Nov',
'Dec'
)
)
)))))))))

It was a bit too much but it solved the problem.