I have got a spreadsheet in where dates are in column B and values are in column E.
Dates are with the format: dd/mm/yy
Values are with the format: XXX,XX€
I am trying to sum cells based on dates but I can't.
I am using the function SUMIFS like this to calculate the values from November:
=SUMIFS(E9:E1000;B9:B1000;">="DATE(2014;11;1)&"<="DATE(2014,11,30))
I am doing something wrong but I don't know what.
In order to get the conditional Sum for specified date range (Nov 2014), correct your syntax as shown in the sample below:
=SUMIFS(E9:E1000,B9:B1000,">="&DATE(2014,11,1), B9:B1000,"<"&DATE(2014,12,1))
Note: this solution is pertinent to the US date format: mm/dd/yyyy, so you may need to correct it per your case depends on how DATE() function is set on your PC. Also, due to my regional settings it's using a comma-separator, which may be different from the one on you PC (you may need to use semicolon ;).
Hope this will help. Kind regards,
Perhaps:
=SUMPRODUCT(--(B9:B1000>=DATE(2014,11,1))*(B9:B1000<=DATE(2014,11,30))*(E9:E1000))
Related
I have two date rows. Both are formatted as dates. When I do a logic test to see whether the two dates, excel is not recognizing them as the same.
Here is a screenshot of the cells:
This is to confirm that both cell rows are formatted as date:
This is to confirm that the equality check row is referencing the right cells:
I'm stumped. Does anyone have any idea what's going on here? Thanks
If you have confirmed that both are actually dates, and not text masquerading as dates, then time is most likely the issue. Note that time is represented via the decimal such that .5 equals noon.
Assuming you just want to know if the dates match independent of time you can use
INT(G4) = INT(G6)
If you want to compare just the dates use:
=Floor(G4,1) = Floor(G6,1)
Format can mask the real cell value. Format both cells as General, then you can see the difference.
If a cell stays a "date" when it is formatted as General, then the cell is most likely text, not a date.
When formatted as General, you can clearly see if the number has any decimals, i.e. time on top of the date.
I was wondering if there was a way to use the CDate function in a countif statement? I'm trying to find dates less than 2 weeks old, am and currently using this statement:
=COUNTIF(CDATE(Table1[Date Closed]),">=" &TODAY() - 14)
I need to turn the Date Closed of the table into actual dates without changing the table (right now they're in the format 13-Mar-2018 but as text format).
Is there a way to do this within the Countif function or am I going to have to do a a VBA code to first change the dates?
Thank you!
=SUMPRODUCT(--(DATEVALUE(Table1[TextDates])>=(TODAY()-14)))
Although I do wonder why you can't have dates as real Excel dates, rather than text strings
Set up your table and insert a column (you could hide the original or place the new column at the end or next to the original) and convert the text date to a date via the DATEVALUE() function.
See reference:
https://support.office.com/en-us/article/datevalue-function-df8b07d4-7761-4a93-bc33-b7471bbff252
You may want to apply format to the new cell/column to look like a date.
Set up your table for "Using structured references with Excel tables."
See reference:
https://support.office.com/en-us/article/using-structured-references-with-excel-tables-f5ed2452-2337-4f71-bed3-c8ae6d2b276e
Count dates based on your condition.
See reference:
https://support.office.com/en-us/article/count-numbers-or-dates-based-on-a-condition-976d0074-245d-49e6-bf5f-1207983f82ed
I'm searching without success for solution to this problem, as mentioned in title.
The following:
I have many cells with numbers, like: 20170510
This is actually a date: 10th of May 2017
Now my question, how can I bring this number in the proper form to build the right date like: 05/10/2017? So that Excel recognizes it as a date.
Any help would be really appreciated.
Assuming your date string is in A2, then try this...
=DATE(LEFT(A2,4),MID(A2,5,2),RIGHT(A2,2))
For a column of such numbers choose Text to Columns with Tab as delimiter and Date format YMD.
A much simpler formula for you to try,
=TEXT(TEXT(A1,"0000-00-00"),"mm/dd/yyyy")
The advantage of this formula is, you can change the mm/dd/yyyy format to any other format of your choice and it would work.
dd-mmm-yy , dd/mm/yyyy etc...
Three columns below, I'm attempting to use column C as a formula that checks against a hard coded date.
8/18/14 12/19/20 formula
In column C =IF(AND("10/7/15">=A1,"10/7/15"<=B1),"IN","OUT")
What I'm looking for is to tell if 10/7/15 is between 8/18/14 & 12/19/20 - I would expect that to come back with a value of IN but it doesn't.... hoping its something simple I'm missing
I think the problem is you're comparing a date (which translates to a number) to a text string. It's a crap-shoot as to what Excel will do in this case. If you compare a date to a date, I believe you will get the desired behavior:
=IF(AND(DATE(2015,10,7)>=A1,DATE(2015,10,7)<=B1),"IN","OUT")
The datevalue function should also work.
If you really have a date in A1, you can try:
=IF(AND(VALUE("2015-10-07")>=VALUE(A1),VALUE("2015-10-07")<=VALUE(B1)),"IN","OUT")
I have two columns in Excel, formatted as General - with this data:
Column A Column B
11/2/2014 9:12:27 AM 12/3/2014 2:00:00 AM
How can I find the difference in hours between them, if they are formatted as "General" and not "Date"?
Thank you for any advice,
Mark
I assume that means these are actually text formatted datetimes - you can test by trying to change the format, e.g. try to change to "Number" - if nothing changes theses are text values.
You can still subtract, though, if the datetimes are in a valid format for your region.
Try using a simple subtraction like
=B1-A1
custom format result cell as [h]:mm
I get the result 688:47 (which assumes that the first timestamp is 11th Feb not 2nd November)
Please try:
=VALUE(B1)-VALUE(A1)
custom formatted as[HH].