maybe 30. It's a calendar spreadsheet where I'm looking to quantify the
number of times a task is mentioned. I've been manually cutting and
pasting it and figured there's got to be a better way. If I could also
log the date of each occurrence that would be optimal. The date is
listed on the first row of each column.
The post deepens .. <g>
Here's a set-up which might satisfy ..
A sample construct is available at:
http://www.savefile.com/files/8637617
Count task occurence n List dates of occurence.xls
In sheet: X,
Source table is assumed within B1:AF10 (31 cols),
header dates in B1:AF1 , data in row2 to 10
Using 31 empty cols to the right (AH to BL)
In AH2, copied to BL2, filled down:
=IF(TRIM(Y!$A$1)="","",IF(ISNUMBER(SEARCH(TRIM(Y!$A$1),B2)),COLUMN(),""))
(AH1:BL1 is left empty)
In sheet: Y,
The item to search will be input in A1
In A2, copied down:
=IF(TRIM(A1)="","",SUMPRODUCT(--(ISNUMBER(SEARCH(TRIM($A$1),X!$B2:$AF2)))))
In B2, copied across to say, K2*, then filled down:
=IF(ISERROR(SMALL(Z!$AH2:$BL2,COLUMN(A1))),"",
INDEX(Z!$B$1:$AF$1,MATCH(SMALL(Z!$AH2:$BL2,COLUMN(A1)),Z!$AH2:$BL2,0)))
*assuming a max of up to 10 dates is expected per item input in A1
(to cover the full show, copy B2 across by 31 cols)
A2:A10 will return the occurences count
of the input item in A1, eg: bob
within rows 2 - 10 in the source table in X.
And the corresponding dates for the occurences
will be listed next to the counts, all dates bunched neatly to the left
---