I want to tally a column but dependent on the text in the next column

Tristram_ZX81

New Member
Joined
Jun 22, 2021
Messages
45
Office Version
  1. 365
Platform
  1. Windows
Hello. I'm using Office 365. I want to type a formula into the cells in the table below (columns M-S) that would tally how many occurrences there are of the D, M and N letters in the I column for each day of the week. So Monday should read

Mon
D 0
M 4
M 1

Tuesday should read

Tue
D 3
M 1
N 2

And so on. Please can someone advise?

1671041555139.png
 

Attachments

  • 1671041464228.png
    1671041464228.png
    6.4 KB · Views: 3
  • 1671041473235.png
    1671041473235.png
    7.1 KB · Views: 3

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
can you change the table to use the same full day name - ????

if so then a simple countifs()
otherwise a sumproduct - see below

Book5
HIJKLMNOP
3
4
5mMondayMondayTuesdayWednesdayThursday
6mMondayD0310
7nMondayM4120
8mMondayN1230
9mMonday
10mTuesday
11nTuesday
12nTuesday
13dTuesday
14dTuesday
15dTuesday
16dwednesday
17nwednesday
18nwednesday
19nwednesday
20mwednesday
21mwednesday
Sheet1
Cell Formulas
RangeFormula
M6:P8M6=COUNTIFS($J$5:$J$21,M$5,$I$5:$I$21,$L6)



Book5
HIJKLMNOPQ
3
4
5mMondayMonTueWedThu
6mMondayD0310
7nMondayM4120
8mMondayN1230
9mMonday
10mTuesday
11nTuesday
12nTuesday
13dTuesday
14dTuesday
15dTuesday
16dwednesday
17nwednesday
18nwednesday
19nwednesday
20mwednesday
21mwednesday
22
Sheet1
Cell Formulas
RangeFormula
M6:P8M6=SUMPRODUCT( (LEFT($J$5:$J$21,3)=M$5)*($I$5:$I$21=$L6) )
 
Last edited:
Upvote 0
Thanks Etaf. For some reason I can't get that formula to work in my document, as per the screen grab below:

1671561025392.png
 

Attachments

  • 1671560944307.png
    1671560944307.png
    15.7 KB · Views: 5
Upvote 0

Forum statistics

Threads
1,214,912
Messages
6,122,200
Members
449,072
Latest member
DW Draft

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top