Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

user setting date

Former Member
0 Kudos

Hi,

how to get user setting date format or if we are uploading a file having date in some other format then how to get the sap user seeting date format

thanks

3 REPLIES 3

ferry_lianto
Active Contributor
0 Kudos

Hi Bobby,

Have you looked this FM <b>DATUMSAUFBEREITUNG</b>?

or you can check table <b>USR01</b> for field <b>DATFM</b>.

SELECT SINGLE DATFM
FROM USR01
INTO (V_DATFORMAT)
WHERE BNAME = SY-UNAME.

Hope this will help.

Regards,

Ferry Lianto

Please reward points if helpful.

Former Member
0 Kudos

Hi bobby,

1. We need not worry about user settings

of date format if we follow these two things.

2.

a) Upload in a date type variable

always in the format YYYYMMDD

b) If this value, goes directly into some

table, then use the same variable

c) if we want to use this date in some BDC,

then

a) take another variable of dt(10) type c.

b) write orgdate to dt.

c) now use this new variable dt

(note : Write will always write

as per the current users settings

to the variable dt)

regards,

amit m.

Former Member
0 Kudos

You can use

CONVERSION_EXIT_SDATE_INPUT AND CONVERSION_EXIT_SDATE_OUTPUT to convert to respective format.

INPUT will convert to the internal format of SAP and OUPUT will convert to user's default format.

Regards,

Ravi

Note :Please mark the helpful answers