Trouble getting distinct results (SOLVED)

@tony-brunsman Fantastic! I only had to make one small change. I changed newItem . count = item . count ; to newItem . count = ‘’ + item . count ; and it all works great now. Again thanks so much I really appreciate how you explained everything rather than just giving the answer. I learned a lot.

Final Code:

$w . onReady ( function () {

$w ( "#filter" ). onClick (( event ) => { 
    $w ( '#repeater' ). onItemReady (( $item ,  itemData ,  index ) => { 
        $item ( '#count' ). text  =  itemData . count ; 
        $item ( '#title' ). text  =  itemData . name ; 
    }); 
    **const from**  =  $w ( '#fromDate' ). value ; 
    **const**  to  =  $w ( '#toDate' ). value ; 
    **const**  filter  =  wixData . filter (). between ( "_createdDate" ,  **from** ,  to ); 
    wixData . aggregate ( 'tutorial_logs' ) 
        . filter ( filter ) 
        . group ( "name" ) 
        . count () 
        . descending ( 'count' ) 
        . run () 
        . then (( results ) => { 
            **let**  index  =  0 ; 
            **const**  newArray  =  results . _items . map ( item  => { 
                **const**  newItem  = {}; 
                index ++; 
                newItem . _id  =  index . toString (); 
                newItem . name  =  item . name ; 
                newItem . count  =  '' + item . count ; 

                **return**  newItem ; 
            }) 
            // now assign the newly formed array to the repeater 
            console . log ( newArray ) 
            $w ( "#repeater" ). data  =  newArray ; 
            $w ( "#repeater" ). show (); 
        }); 
}) 

});