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!

Formula to determine time between a log out and next log in

Status
Not open for further replies.

jschmidt1

IS-IT--Management
Joined
Aug 13, 2015
Messages
12
Location
US
Hello,
I'm hoping someone can help me. I've searched many, many posts and can only come up with the following formula using DateDiff("m", {datetime1}, {datetime2}) and it's not calculating what I need. I have the following report:

USER_ID LOGINDT LOGOUTDT Login Profile hh LoginTim Sr

James 8/4/2015 7:31:12AM 8/4/2015 1:20:39 05:49:27 20,967 Specialist_Qu
James 8/4/2015 1:55:34PM 8/4/2015 6:00:15 04:04:45 14,685 Specialist_Qu
8/4/2015 James 09:54:12 35,652

I'm trying to calculate the time in minutes between 1:20:39 (LOGOUTDT) and 1:55:34 (LOGINDT) = 0:34:55

Thank you in advance!

James
 

Interval Type Values

Interval Type Description
yyyy Year
q Quarter
m Month
y Day of year
d Day
w Weeks

If Date1 is on a Tuesday, counts the number of Tuesdays between Date1 and Date2 not including the initial Tuesday (Date1). (It will count the last Tuesday if Date2 falls on a Tuesday.)

ww Number of firstDays between dates
Almost identical to w, except it counts the day you specify rather than the day Date1 falls on.

h Hours
n Minutes
s Seconds
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top