Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

batch file converting to time 2

Status
Not open for further replies.

ziggs

Technical User
Sep 21, 2000
195
US
I have a batch file that produces a line of date/time that looks like this:

Sat 08/30/2008 17:30:51.09
Sat 08/30/2008 17:39:28.25
Sat 08/30/2008 17:57:39.57

In CR8, I want to show how many seconds (rounded off to one second) it took for the next line. Thus, the report would look like:

Sat 08/30/2008 17:30:21.09
Sat 08/30/2008 17:39:28.25 9 Seconds
Sat 08/30/2008 17:57:39.57 11 Seconds

 
Use a formula

If not onfirstrecord then
datediff("s", datefield, previous(datefield))
else
0

Ian
 
A little correction since you are sorting in ascending datetime order:

datediff("s", previous(datefield), datefield)

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top