Re: Getting the month name from a date



This should work in any version of Access:
Format([MyDate], "mmmm")

More recent versions support MonthName(), so if you want a more
circumlocutory approach that fails in older versions:
MonthName(Month([MyDate]))

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"David Gartrell" <davidg@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:8P-dnfWcrMmEcznZRVny0A@xxxxxxxxxxxx
Hi there,

Could anyone help me with a little problem i'm having in SQL.

What I'd like to be able to do is to extract the name of the month from
any date so that I can group figures in a report by the name of the month.
I've tried using both the MONTH and DATEPART functions but all i've
succeeding in doing so far is getting the month number e.g. '6' rather
than the month name 'JUNE'. I thought that if I specified "mmmm" in the
date part function instead of "m" then it would return the name of the
month, but instead all it gave me was an error.

If anyone can tell me a way of doing this then i'd be very grateful

Many thanks

David


.