Application Development and Automation 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:Ā 
Read only

Function module for date and time conversion in SRGBTBREL table

Former Member
0 Likes
1,051

Hi All ,

I have field  UTCTIME in table SRGBTBREL .

in Selection screen i'm entering date and time depending on selection criteria it should display value in grid .

in table date and time is stored as 20,130,205,055,431 format .

can any one tell me how to convert date(YYYYMMDD) and time(HH:MM:SEC) from selection screen to above format mentioned in table .

3 REPLIES 3
Read only

Former Member
0 Likes
715

Hello,

         Use FM : IB_CONVERT_INTO_TIMESTAMP

Read only

Rushikesh_Yeole
Contributor
0 Likes
715

You can use FM OIL_DATE_TO_TIMESTAMP. Just pass date and time. It will give ypou time stamp in reuired format.

Read only

0 Likes
715

Hi Smitha,

Try the following code:

DATA: time_stamp TYPE timestamp,
      dat
TYPE d,
      tim TYPE t,
      tz  TYPE ttzz-tzone.

tz = 'INDIA'. "Time Zone
dat = '20030309'. "Date
tim = '013000'.   "Time


CONVERT DATE dat TIME tim
        INTO TIME STAMP time_stamp TIME ZONE tz.