I have several dates in a spreadsheet:
I would like to get the weeknumber in the column B for the date in column C in european time.
I tried something like that(and also that above):
= MID(TEXT(C2,"dd.m.yyyy"), 3, 2)
However that only gives me .2 in the B column...
Any suggestions on how to implement/start that?
I really appreciate your answer!
PS.: I also added excel tags because its similar to google spreadsheet. There is probably a chance that I can implement something from excel in google spreadsheet
in excel for get week number use
=WEEKNUM(C2)
Use the following formula
WeekDay(c2)
It will return the week day number.
Related
I need to count all dates that are "less than" today to see which work is overdue. I understand that this can be done simply with
=countif(F:F,"<"&TODAY())
However, the dates in Column F are formatted like "12/05 - Evening" instead of just "12/05". Because of this, the formula is not picking up anything. Does anyone know how to change this code so that it counts any cell that contains dates prior to today, even if there is other text in the cell? I've tried playing around with these "**", but can't get it to work.. Thank You!
So based on my comment I would get the date by using left() with find() like so:
LEFT(A1,FIND(" ",A1,1)-1)
Then format as short date and it behave as a date.
From comment:
Use a helper column and separate the date out then use the countif() on that column
I have the following time series dataset from ebuttons.
When I extracted something wrong happened and in most of the data of each buttom I get some times formatted as follows
I have tried several things
1)= text(cell number , "hh:mm:00) in excel
2)I have also tried to separate date and time in excel by holding date constant
3)In rstudio I have used different function as as.POSIXct(concrete$time_date, format = "%m-%d-%Y %H:%M:%S") and as.Date
But there is something really wrong as I get this when trying option 1 and 2 in excel:
I think the time AM/PM whatever I tried is recognized as a text. But I do not know what else to try after having change format in different ways.
I am working on MAC
I really appreciate our attention in advance,
Best
Mara
Considering A1 as the first cell with data, try this one:
Select column B and give format as short date in the way you need.
Select column C and give format as Hour in the way you need.
On A2 place formula =MID(A1,1,8) (Maybe instead of 8 is 9, but check your data)
On A3 place formula =TIMEVALUE(MID(A1,9,20))
Drag the formulas down.
Hope it helps!
Hello I am trying to use a simple excel sheet (last name, first name, date of birth, date of hire) for an employee listing to then create a list of birthdays (pro[bably +/- 7 days) - just the last & first name. Secondly the same thing for the hire date (probably +/- 14 days) and the years of service, that calculation I figured out easily.
I was trying to do this with if statements or datedif and am struggling.
maybe this isnt the proper tool, any thoughts, suggestions would be greatly appreciated!
Please see sample data screen shot below:
expected output:
Maybe this would be better as a vlookup?
Thank you
OK, so here is what I came up with based on my understanding of the question:
=IF(OR(DATEDIF(B2,TODAY(),"YD")<=7,DATEDIF(B2,TODAY(),"YD")>=359),A2,"NO")
The formula here takes number of days between the birthday and today (ignoring the years) and checks if they're less than or equal to 7 or more than or equal to 359.
Sample spreadsheet: https://www.dropbox.com/s/kxgi9eeoikems66/Birthday.xlsx?dl=0
Insert two more columns for month of birth and month of hiring. Add the following formula in both consecutively
=TEXT(C1,”MMMM”) and =TEXT(D1,”MMMM”)
The final sheet will look like this
After that select all of your data and insert Pivot table and format it like the below
You will get an auto updatable sheet without any macros and extra work
I´ve spent a lot of time with a formula in Excel and I´m still blocked. I hope you can help me.
I have a table in Excel with several values as shown in this
screenshot.
What I´m trying to extract is the number of Fruits sold in a specific month. That is, how many lemons were sold in January 2016, for example. This is the formula I´m using:
=SUMPRODUCT((B3:B38=E4)*(MONTH($A$3:$A$150)=12)*(YEAR($A$3:$A$150)=2015);$C$3:$C$150)
But the result is #N/A as seen in the screenshot.
What Am I doing wrong? Any help, please?
Thanks a lot in advance!
You can use arrays in excel to get this answer
{SUM(IF(MONTH(F$3&"1")=MONTH($A$3:$A$150),IF($E4=$B$3:$B$150,$C$3:$C$150,0),0))}
You can use this Sumproduct formula which uses array logic:
SUMPRODUCT((MONTH($A$3:$A$38)=MONTH(TEXT(G$2,"MMM")&1))*($C$3:$C$38=$F4)*
($D$3:$D$38))
Sumproduct Demo
Part of your problem is your ranges are not equal in length. B3:B38 has to be the same number of rows as $A$3:$A$150 and C3:C150. When rows are not equal things blow up on you.
=SUMPRODUCT(($B$3:$B$150=$E4)*(MONTH($A$3:$A$150)=12)*(YEAR($A$3:$A$150)=2015);$C$3:$C$150)
if you change your header row to be actual excel date format, and then change the cell display format to just show the month (as suggested by csanjose), then you can adjust your sumproduct formula as follows and copy to all cells in your table.
=SUMPRODUCT(($B$3:$B$38=$E4)*(MONTH($A$3:$A$150)=Month(F$3))*(YEAR($A$3:$A$150)=Year(F$3));$C$3:$C$150)
Fill your month-row with the last day of each month, then apply date format to show only month name.
The formula you should use is, for example, in g8:
=SUMIFS($C:$C;$B:$B;$E8;$A:$A;"<="&G$3;$A:$A;">"&F$3)
First column "F" doesn't have a column on the left to compare, so you can put a date in E3 or change a bit the formula (example of F8):
=SUMIFS($C:$C;$B:$B;$E8;$A:$A;"<="&F$3;$A:$A;">2015/12/31")
Take a look at the result
If you don't want to use a pivot table, you can use this formula to get what you need:
=SUMPRODUCT(($B$3:$B$150=$E3)*(MONTH($A$3:$A$150)=1)*(YEAR($A$3:$A$150)=2015)*$C$3:$C$150)
Then drag-fill the cell to copy it to every month column (just make sure you change the month number in the formula (and year if you're doing that too)), and then drag-fill down the columns.
That should work pretty food good :)
Good Luck!
I'd like to organize dates in an excel spreadsheet into 2 month blocks. So if a date is in January or February, I'd like a function to return "Jan-Feb". If a date is in March or April, I'd like it to return "Mar-Apr" etc. I'm a complete novice at excel formulae. Any help would be greatly appreciated.
Try first creating an index which lists all the possible month combinations. ie, in cells J1:J12, enter "1" "2"..."12". Then in K1:K12, enter "January-February" "January-February""March-April""March-April"..."November-December".
Then put this formula instead of what you have above:
=index($K$1:$K$12,Match(Month(H3),$J$1:$J$12,0))
This works similar to a vlookup function - if you are more comfortable using vlookup, it would look like this:
=vlookup(month(H3),$K$1:$J$12,2,0)
Basically either function searches column K for the number of the month in H3, and then it provides the text string that you have manually typed in that row in column J.