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

time stamp problem

Former Member
0 Likes
397

Hi Every one,

I have file to upload from application server.

file name is like 'PPRICE'TIMESTAMP'.CSV'

from this file name i have to read the TIMESTAMP

I can read it like

tstamp = file+10(leng of timestamp).

now this tsamp is in character format.

i have to validate the current date with the time stamp i read into tstamp.

so here is my problem

how do i compare a character with the type timestamp.

please some one help me.

3 REPLIES 3
Read only

Former Member
0 Likes
369

Declare one more variable of type CHAR , and move the TIMESTAMp to that variable , and compare that with ur char variable

data : v_char(14).

move timestamp to v_char.

compare v_char with ur char variable

Read only

0 Likes
369

Thing is that

the characters (time stamp) that iam reading from the file name

is a time stamp, iam reading in to character variable.

from the timestamp i have to take the date separately and check with

the current date

Read only

Former Member
0 Likes
369

try this


data : timst(8) type c value '10:10:10',
       timestamp type t.

replace all occurrences of ':' in timst with space.
condense timst.
timestamp = timst.
if sy-uzeit gt timestamp.
endif.

regards

shiba dutta