• The table has 4 columns

    ICN, From Date of service, To date of service, and detail status code

    123,1/1/12 ,1/5/12 ,P

    123,1/6/12 ,1/6/12 ,p

    123,1/1/12 ,1/10/12 ,p

    For each ICn I need to count only the distinct days per icn. in this example above, the answer would be 10. I dont want to count each day, but want the count of distinct days per ICN.

    does that help?