Hey I'm new to this forum but I have a question that I hope can be easily answered by someone more knowledgeable in Excel functions than myself. I looked at an old thread where someone was wanting to count the consecutive dates as a single occasion and the formula given works, however it utilizes the Networkdays function and I need to include any and all dates. This is for a count of consecutive dates per patient admission so weekends and holidays are to be included in this count.

I couldn't figure out how to change this function to allow for weekends. Thank you. I greatly appreciate any help I can get with this. This is a report request that I have to manually put together and I'm just stumped.



Function to count consecutive dates as one occasion
=--((NETWORKDAYS(SUM(c1)*(B1=B2),c2)-1)>1)

Column A Column B Column C Column D ( I would then use this column in a pivot table to calculate)
pat name pat id date of service # Admissions

ex:

12345 07/22/2013 1
12345 07/23/2013 0
12345 11/01/2013 1
67890 05/04/2014 1
67890 05/05/2014 0 etc,