ABAP how to write a date as a long text?

ilya n. picture ilya n. · Oct 13, 2009 · Viewed 20.8k times · Source

I need to split ABAP date like

     20091101 --> "01", "november", "2009"

The "01" and "2009" are trivial, but how do I get the month name (which should be localized)?

Is there a function to do that?

If there is no such function, perhaps a table with month names?

Answer

PATRY Guillaume picture PATRY Guillaume · Oct 13, 2009

You can get the month's name in a given language using the module function 'MONTH_NAMES_GET', passing the language as a parameter. The day (Sunday for example) can also be obtained using 'RH_GET_DATE_DAYNAME'

Guillaume