Question Locked

How would I comapre date fields in Excel?

0 helpful
2 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

With data that looks like this:
RECEIV AT DELIVER ED SIGNED BY
DATE/TIME DATE/TIM E DELIVERED BY
---------- ---------- ------------------------------------------

9/6/2011 9/6/2011 dianalebasco
10:49 13:57 Omar Rivas
---------- ---------- ------------------------------------------
9/2/2011 9/6/2011 PAGAN, EDWIN
11:15 9:19 JOSE POMA
---------- ---------- ------------------------------------------
9/22/2011 9/22/2011 myers.george
12:01 13:00 JOSE POMA
---------- ---------- ------------------------------------------

How can I compare the time data to see if something was less than 24 hours. Example: I want to use a formula to if 9/6/2011 at 10:49 is more tha 24 hours from 9/6/2011 at 13:57? With the date and time being on 2 separate lines is this even possible? Thanks.

2 replies

by tobif

The internal Excel format for date&time encodes the date in the integer part, and time of day in the decimal part. You can sum them to each other before doing the comparison.

However, if you receive this data just as pure text (say in a text tile), then perhaps a better approach is to write a macro that will chew the data into one entry a line?

This discussion is closed to new replies.