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

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Make month name from today()

I´ve set monthNames to

MonthNames='01;02;03;04;05;06;07;08;09;10;11;12';

because I use them in various variables.

I need a variable that gives me the CurrentMonthName = NOV

1 Solution

Accepted Solutions
ali_hijazi
Partner - Master II
Partner - Master II

then this should work

= Pick(Month(Today()), 'Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec')

put this in a textbox and see

I can walk on water when it freezes

View solution in original post

9 Replies
anbu1984
Master III
Master III

Let CurrentMonthName = Month(Today());

deepakqlikview_123
Specialist
Specialist

You can use if else condition

if(Month='01',Jan,if())

Aurelien_Martinez
Partner - Specialist II
Partner - Specialist II

Hi,

Let CurrentMonthName = Pick(Month(Today()), 'Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec');


Aurélien

Help users find answers! Don't forget to mark a solution that worked for you!
ali_hijazi
Partner - Master II
Partner - Master II

use the function MonthName(Today())

this will give you Nov-2014

I can walk on water when it freezes
Not applicable
Author

Hi Aurelien

The above does´nt work

I tried to make a new variable in Settings

Variable name: Let CurrentMontName

Definition. =Pick(Month(Today()), 'Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec');

It does´nt give me Nov for today on this 14. november 2014??????

Not applicable
Author

Hi Ali

Because I´ve set Monthnames in hte beginning af my script to


SET MonthNames='01;02;03;04;05;06;07;08;09;10;11;12';

the MonthName(Today()) gives me 11

Aurelien_Martinez
Partner - Specialist II
Partner - Specialist II

See this QV file

Aurélien

Help users find answers! Don't forget to mark a solution that worked for you!
ali_hijazi
Partner - Master II
Partner - Master II

then this should work

= Pick(Month(Today()), 'Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec')

put this in a textbox and see

I can walk on water when it freezes
Not applicable
Author

Hi,

try these

Month(today()) is give monthname

Or

Pick(Month(Today()), 'Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec')