2012 Apr 20 6:55 AM
Hi Experts,
There was a problem in my time stamp.
In my web dynpro compinent i am using timestamp feature for comments.
for every comment i posted in a table i am also adding times stamp with this comment but when i see this time stamp in the table its giving wrong time
Following is the statement
CONVERT DATE sy-datum TIME sy-uzeit INTO TIME STAMP ls_comments-timestamp TIME ZONE sy-zonlo.
time zone sy-zonlo is EST. Time is showing almost 5 hours forward
2012 Apr 20 12:33 PM
That's the way timestamp works. You have local time zone set as EST, the timestamp calculation is then based upon UTC - local time zone, for which I typically have a five hour difference. Try creating your time zone with time zone set to space in a variable. I did that, as I recall, to force local time into the table in one of my programs.
2012 Apr 20 9:58 AM
Hi,
I dont think you need to concatenate to get the timestamp.You can directly write like below:
get time stamp field v_timestamp.
For help you can refer to the below link:
http://help.sap.com/abapdocu_70/en/ABAPGET_TIME-STAMP.htm
Hope it solves your problem.
2012 Apr 23 9:01 AM
2012 Apr 20 10:00 AM
In the table it must be storing the timestamp as per the system time-zone. Check your Time-Zone and System timzone.. I believe you will get the difference between these two time zone as 5 hours
2012 Apr 20 12:33 PM
That's the way timestamp works. You have local time zone set as EST, the timestamp calculation is then based upon UTC - local time zone, for which I typically have a five hour difference. Try creating your time zone with time zone set to space in a variable. I did that, as I recall, to force local time into the table in one of my programs.
2012 Apr 25 6:26 AM