If you are using database then it can be done easily at database level.
sample code for oracle database.
[CODE=oracle]select to_char(to_date (amt,'j'),'jsp' ) from salary;[/CODE]
it can be executed at database in a function returning the string in words.
Comment