Share via


Get the name of a month - PowerPivot v2

Question

Friday, March 22, 2013 4:55 PM

Hi,

I need to determine the month name as a calculated column into a Time table with a date field as the pk of the table.

I've used this formula: FORMAT(MONTH([Data]);"mmm")

but unsuccessfully.

Month names don't correspond with the month.

Any suggests, please?

All replies (2)

Friday, March 22, 2013 8:31 PM âś…Answered | 6 votes

This one came up yesterday too. 

To use a date format (like "MMM" for month name), you need to pass the function a proper date.  Not just an int for the month part.

Try passing the full date (remove the MONTH() function).  And uppercase MMM is needed for month name abbreviated. 

=FORMAT([Date],"MMM")

Let me know if that helps.

Brent Greenwood, MS, MCITP, CBIP // Please mark correct answers and helpful posts // http://brentgreenwood.blogspot.com


Saturday, March 23, 2013 4:57 AM

Ok, Brent, it functions. Many thanks.

I've read this blog: http://daxtips.wordpress.com/2012/01/18/get-month-name-from-a-date-field/

So I think it was wrong.

Bye