Format Forumula

I am using the below formula in BO XI.  I am trying to retun the monh name followed by the 4 digit year.  However, my year is formatting like "2,008.00" instead of "2008"

Any ideas on how I can format this to display properly?

Thanks

TOTEXT(
    IF MONTH({Rpt453;1.POST_DATE}) = 1 THEN 'JAN ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 2 THEN 'FEB ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 3 THEN 'MAR ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 4 THEN 'APR ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 5 THEN 'MAY ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 6 THEN 'JUN ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 7 THEN 'JUL ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 8 THEN 'AUG ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 9 THEN 'SEP ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 10 THEN 'OCT ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 11 THEN 'NOV ' & YEAR({Rpt453;1.POST_DATE}) ELSE
    IF MONTH({Rpt453;1.POST_DATE}) = 12 THEN 'DEC ' & YEAR({Rpt453;1.POST_DATE})
)

Open in new window

gdspeareAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

mlmccCommented:
Use this

ToText(YEAR({Rpt453;1.POST_DATE},0,'')

An easier way

MonthName ({Rpt453;1.POST_DATE},True)  & ' ' & ToText(YEAR({Rpt453;1.POST_DATE},0,'')

If you need it in uppercase the
UCase(MonthName ({Rpt453;1.POST_DATE},True)  & ' ' & ToText(YEAR({Rpt453;1.POST_DATE},0,'') )

mlmcc
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
gdspeareAuthor Commented:
I'm getting the error that a number is required on the monthname function?

Ideas?
0
gdspeareAuthor Commented:
I got it with a slight change.

MonthName(Month({Rpt453;1.POST_DATE}),TRUE) & ' ' & TOTEXT(Year({Rpt453;1.POST_DATE}),0,'')
0
wykabryanCommented:
MonthName (Month({Rpt453;1.POST_DATE}),True)  & ' ' & ToText(YEAR({Rpt453;1.POST_DATE},0,'')


or

UCase(MonthName (Month({Rpt453;1.POST_DATE}),True)  & ' ' & ToText(YEAR({Rpt453;1.POST_DATE},0,'') )
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Crystal Reports

From novice to tech pro — start learning today.