Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Working with SAP Timestamp field

I am having a hard time working with the Timestamp field in Crystal Reports.  The field is formatted as a number and looks like 20,151,021,123,019.10.

The ultimate goal of my report is to open the report, refresh the data with the date being "Today - 1".  In order to do that I need to use the Timestamp field in the table.  I have been able to work with the field so that I can input "10212015" but I want it to do it automatically.  I want to be able to schedule this in BO and run based on the "Today - 1" forumula.

Any help would be greatly appreciated.

This is what is working right now:

@mydate

stringvar date1;

stringvar date2;

stringvar yr;

stringvar mn;

stringvar dy;

date1:= totext({_COCKPIT_TMSG.CR_TIMESTAMP},0,"");

yr:= left(date1,4);

mn:= mid(date1,5,2);

dy:= mid(date1,7,2);

date2:= (mn&dy&yr)

Selection:  @myDate = "10212015"

Former Member
Not what you were looking for? View more on this topic or Ask a question