• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Booking Counter Issue

David Lam

New Member
Hi,

I have a issue that is very similar to the spreadsheet attached. Each day I get dumped raw data. I arrange it by name and date from earliest date to the latest date. I have been using countif up to this stage and it works. But now my issue is someone has suggested to split the bookings by topic and now my counter off. I am counting a booking on the same date as something new and my sequence it out. Is there another formula to fix this? :(

 

Attachments

Hi Ali, I believe if I insert another criteria in a COUNTIFS formula it will reset my counter. Do you have a specific criteria for this or example of this on the sample worksheet?
 
Wow it works. Thank you p45cal. I'll see if the logic works on a bigger set of data. I have been heavily reliant on the COUNTIF formula so I was trying different combinations with AND and > but failed. Who knew it was so simple on your one.
 

Attachments

Hi ,

The formula you posted did not make use of COUNTIFS ; if it had , it would have worked.

See the attached file.

Narayan

That would be correct, I had been using COUNTIF up to this point. It was working in the past until we decided to separate the bookings by topic. It should treat multiple bookings on the same day as 1 booking. My issue is the COUNTIF formula was treating each line as a booking, so I am double counting multi-sameday bookings. Sorry for the confusion. p45cal one seems to be working. I haven't had the chance to dump a big data set on it.

 

Attachments

Last edited:
in Q9:
=IF(AND(K9=K8,L9>L8),Q8+1,IF(AND(K9=K8,L9=L8),Q8,1))
copied down gives tthe same results as your goal but I may have misunderstood the logic, so test it.

And this shorter formula produce the result same as p45cal's formula.

=IF(K9<>K8,1,IF(L9=L8,Q8,N(Q8)+1))

Regards
Bosco
 
Last edited:
Back
Top