Get the quarter from a date
="Q"&ROUNDUP(MONTH(A2)/3,0)Excel · result on the sample sheet: 6 rows (B2:B7)
Describe what you need and get a working MONTH formula for Excel and Google Sheets, tested on real data before you copy it. MONTH returns the month of a date as a number from 1 to 12.
Each formula below was calculated on its own sample sheet. Open one to see the sheet, why it works, and to try it yourself.
="Q"&ROUNDUP(MONTH(A2)/3,0)Excel · result on the sample sheet: 6 rows (B2:B7)
=SUMPRODUCT(--(MONTH(B2:B12)=G1))Excel · result on the sample sheet: 4
=FILTER(A2:B11,MONTH(B2:B11)=E1,"No birthdays")Excel · result on the sample sheet: 4 rows (D3:E6)
=MOD(MONTH(A2)-$E$1,12)+1Excel · result on the sample sheet: 6 rows (B2:B7)
=FILTER(A2:E11,(MONTH(B2:B11)=MONTH(H1))*(YEAR(B2:B11)=YEAR(H1)))Excel · result on the sample sheet: 4 rows (G3:K6)
=TEXT(A2,"yyyy-mm-dd")Excel · result on the sample sheet: 5 rows (B2:B6)
=SUMIFS($C$2:$C$11,$A$2:$A$11,">="&E2,$A$2:$A$11,"<="&EOMONTH(E2,0))Excel · result on the sample sheet: 3 rows (F2:F4)
=DATE(YEAR(B1),MONTH(B1)+SEQUENCE((YEAR(B2)-YEAR(B1))*12+MONTH(B2)-MONTH(B1)+1)-1,1)Excel · result on the sample sheet: 8 rows (D2:D9)
You describe the task in plain English, and it writes the formula, using MONTH where that's the right tool, for your table or a sample one. The formula is run in our engine in Excel and Google Sheets mode before you see it, so you get its result, not just a guess.
MONTH returns the month of a date as a number from 1 to 12.
Yes. Each example below opens a page where you try the formula in a live grid and it's checked as you go, and the MONTH function page has a practice exercise.