#1   Report Post  
M Jones
 
Posts: n/a
Default Change to show time

I have a LARGE (22,000+ rows) excel worksheet with results from a query I ran
to show admit and discharge times. However the times are not in the right
format to perform calculations so I can measure the length of stay. For
example the time 2:15 a.m. is 215....because my query is pulling data from
our mainframe there is little I can do about how the data comes in...I have
already looked to see if I can convert the data or compute the data, but have
been unsuccessful. I have also tried to format the cells so it will show
time as 02:15, but this is not working either. What is working for me is
this....the function TIME. I can put in the function as =TIME(2,15,0) and it
will display the time 2:15 thus enabling me to perform the correct
calculations. But what is the best way, if any, for me to have the entire
spreadsheet done without having to go into each individual cell (which is not
feasible) ? Any suggestions?
  #3   Report Post  
Peo Sjoblom
 
Posts: n/a
Default

The question is how is 2:15 pm displayed, if it is 1415 that you can use a
help column like

=TIME(INT(A1/100),MOD(A1,100),0)

where A1 would hold the time, you can basically copy down the formula 22000
rows and paste special as values over the old values and remove the help
column

If the value should go beyond 24 hours like 3215 for 32:15 then you wopuld
need something like

=INT(A3/100)/24+MOD(A3,100)/1440

which will work for lesser times as well

Format as [hh]:mm

Regards,

Peo Sjoblom

"M Jones" wrote:

I have a LARGE (22,000+ rows) excel worksheet with results from a query I ran
to show admit and discharge times. However the times are not in the right
format to perform calculations so I can measure the length of stay. For
example the time 2:15 a.m. is 215....because my query is pulling data from
our mainframe there is little I can do about how the data comes in...I have
already looked to see if I can convert the data or compute the data, but have
been unsuccessful. I have also tried to format the cells so it will show
time as 02:15, but this is not working either. What is working for me is
this....the function TIME. I can put in the function as =TIME(2,15,0) and it
will display the time 2:15 thus enabling me to perform the correct
calculations. But what is the best way, if any, for me to have the entire
spreadsheet done without having to go into each individual cell (which is not
feasible) ? Any suggestions?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
LOCK TIME confused Excel Discussion (Misc queries) 4 May 23rd 05 08:34 PM
time differences in a column 68magnolia71 Excel Worksheet Functions 3 May 9th 05 09:46 PM
Accumulate weekly time to total time in Excel. delve Excel Discussion (Misc queries) 0 May 4th 05 08:14 PM
enter a time into a cell, have the cell show two times the entry johnp Excel Worksheet Functions 3 May 2nd 05 12:08 AM
Help - Information with time and date PM Excel Discussion (Misc queries) 4 January 6th 05 08:25 AM


All times are GMT +1. The time now is 04:41 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"