Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Has anyone got a slick way of converting a month number to a month name?
I either end up using an inline table ( generally as a mapping / applymap)
1,Jan
2,Feb
etc
or a horrible string function pick(monthno, 'Jan', 'Feb', etc)
Thanks
You can use this:
=SubField(MonthNames,';',1)
1 gives Jan ... and so forth...
MonthNames should be predefined according to your settings in Windows and at the top of your load script.
So in your case it should be:
=SubField(MonthNames,';',monthno)
Month(MakeDate(1,MonthNum))
best way is to do a inline mapping table load and use applymap
Thanks
BKC
Month(Date#(4,'MM'))
Hi,
Try this script
load
Month(MakeDate(Today(), MonthNumber, 1)) AS Month_Name,
* Inline [
MonthNumber
1
2
3
4
5
6
7
8
9
];
Thanks Folks - All great answers
This worked perfectly for me. Thanks.