on 10-22-2015 3:46 PM
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"
Hi Kelvin,
Try using a Record Selection formula that looks like:
Cdate(Picture(Left(totext({_COCKPIT_TMSG.CR_TIMESTAMP},'#'),8), 'xxxx/xx/xx')) = CurrentDate-1
-Abhilash
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
82 | |
10 | |
10 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.