Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 1 year ago.
Improve this question
hi everyone i have one columns is Duration columns, the column is in hour format, and I want to convert it to "hour:minutes" format, what formula can I use in excel?
i use =TEXT(A1/24,"hh:mm")
You need to divide hours by 24. Try below formula-
=TEXT(A1/24,"hh:mm")
Check this article from exceljet.net Convert decimal hours to Excel time.
From #Gary's Student answer, you can also use same format with text function.
=TEXT(A1/24,"[hh]:mm")
With data in A1, in another cell enter:
=A1/24
and format as follows:
Note the brackets in the formatting:
[hh]:mm
The other answers are fine, but I wanted to offer an alternative that does not involve formatting the cell (which may or may not be desirable, although it probably usually is the best way TBH).
The following formula splits the hours and minutes:
=FLOOR(S10,1) & ":" & (S10-FLOOR(S10,1))*60
Related
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 4 years ago.
Improve this question
I want to fuse 3 items to one using concatenate formula. I am trying to fuse date (2018-06-08) and 2 normal text items (12 and 45). I use this formula =Concatenate(D2;" ";E2;":";F2) But when I fuse them, I get 43259 12:45, instead of 2018-06-08 12:45. I tried adding TEXT but it only gave me error.
Try,
=D2+time(E2, F2, 0)
Format the result as you prefer. e.g. yyyy-mm-dd hh:mm
Use this:
=CONCATENATE(TEXT(D2,"yyyy-mm-dd"), " ", E2, ":", F2)
Because Google docs (like Excel) represents dates with a number (usually it's the number of days since 1900-01-01), you need to convert it to text format with special instructions specifying the order of day, month, year, and what punctuation to separate them.
Currently the documentation for the TEXT function can be found here.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
I'm trying to write a vlookup formula that will
1). check for duplicates in the list and
2). if there is a duplicate, then check the dates, and pull the correct rate in the vlookup return value, depending on the date.
So for example, if Michael has a rate of $100 per hour for 7/1/2017, I can assume this is his rate until noted otherwise with an additional line. On 7/3/2017 his rate changes to $120. So for hours worked on 7/1/2017 and 7/2/2017, the rate should be $100, but on 7/3/2017 and on, the rate should be $120, or until a new line is added for Michael indicating a new rate on a specific date.
Can anyone help with this?
Thanks!
You could do something like this if you sort by name and by date descending
Note it's an array formula so you need to use Ctrl+Shift+Enter
You could do this with MAXIFS(). The multiple conditions lets you find the multiple conditions, but MAXIFS() will always return an individual value unlike SUMIFS or COUNTIFS. Place hte formula in cell F2 and fill it down
=MAXIFS('Effective Rate'!$C:$C,'Effective Rate'!$A:$A,A2,'Effective Rate'!$B:$B,"<="&B2)
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 5 years ago.
Improve this question
I need the total number of cells in sheet-1 Column B that are less than 16 hours where Sheet-1 Column A is not equal to 5 in sheet 1 E4 cell.
For Ex please see the image attached.
Please click on this link to find the example
Assuming that
column A of sheet1 are date/times, and not text, and
you are attempting to find how many date/times are more than 16 hours old
then you simply want to place the following formula in sheet2!F7:
=COUNTIF(sheet1!A:A,"<"&NOW()-0.75)
(16 hours is 0.75 of a day.)
If the data in column A is text, then it gets slightly harder as you have to ensure that Excel does not treat the NOW()-0.75 as a date/time. You can trick it by adding an extraneous character to the end of the formatted date/time so that it no longer appears to be valid, e.g.
=COUNTIF(sheet1!A:A,"<"&TEXT(NOW()-0.75,"yyyy/mm/dd hh:mm:ss")&"#")
worked for me. (The extra "#" at the end forced it to no longer be a valid date/time string.)
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 6 years ago.
Improve this question
i want to create a formula like this,
=DATE(YEAR(any)),MONTH((any)),14)
i don't care about year or month only the day.
apparently excel doesn't let me add "any" as a fuction. can someone please help me?
Consider:
=DATE(RANDBETWEEN(1,9999),RANDBETWEEN(1,12),14)
To use the current year and month, use this formula:
=DATE(YEAR(NOW()), MONTH(NOW()), 14)
However, the month does matter if you wanted to put 31 for the day (or 29/30 if the month happens to be February), so you might want to just always use a specific year and month that will allow for maximum flexibility, such as:
=DATE(2000,1,14)
One thing I would suggest is to ask yourself why you are storing this as a date in the first place if you only care about the day of the month. You could just store 14 and label the column "Day of Month". To better answer your question, it would be helpful to know what are you actually doing with these dates.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question appears to be off-topic because it lacks sufficient information to diagnose the problem. Describe your problem in more detail or include a minimal example in the question itself.
Closed 8 years ago.
Improve this question
I am having a small problem with splitting up dates using the Excel delimiter tool. Usually I am able to either do some quick format changes to 'Short Date' or delimit with a non-existent delimiter in order to use the DMY option to standardize format. However, I have exhausted both of those options and nonetheless the dates appear to be mismatched. That is, suppose I take RIGHT(A1,4) in order to obtain only the year for each cell containing a date. Some of these give me the correct year e.g. 1973 and some give me a large number e.g. 6340. Why might this be happening?
In excel dates stored as numbers: e.g. 01/01/2013 is 41275 and Right(A1,4) gives you 1275. Try this one instead:
=YEAR(A1)
or
=TEXT(A1,"yyyy")
first formula returns number 2013 and second formula returns text "2013"
UPD:
as follow up from comments, since dates can be stored as text or as dates, this one works:
=RIGHT(TEXT(A1,"mm/dd/yyyy;#"),4)