Evaluate Time

amulder

New Member
Joined
Oct 28, 2016
Messages
20
Hi,


I am trying to evaluate a time value in a query with a calculated column. I have 2 columns; Login Polling Interval and Logout Polling Interval. If the record is considered logged in at 0600 then I want a 1 in the column. If the record is considered logged out at 0600 then I want a 0 in the column. The Login and Logout values are in 24 hour clock and can span days. So for example the first record logged in at 20:18 and stayed logged in until 06:45 the next morning. So in this record the 0600 column should have a 1 because it was logged in at 0600.


I don't care about the spanning of days, I'm just looking for an evaluation of the 0600 time block. This is what my formula currently is but it is not working:


0600 = IF([LOGIN_TIME]=BLANK(),BLANK(),IF([Login Polling Interval]<=TIMEVALUE("06:00")&&[Logout Polling Interval]>=TIMEVALUE("06:00"),1,0))


large
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"
Let me understand it first if the duration between logged in and logged out passes 6 in the morning than you want 1 otherwise you want a zero
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top