awk, help me - counting items and listing them

This is my first ever post... please help! :o

I have two columns....here is part of the file...

12,                                             46798                                   
6692,                                          46799                                   
5710,                                          46799                                   
12,                                             46799                                   
6692,                                          46800                                   
5710,                                          46800                                   
12,                                             46800                                   
12,                                             46805                                   

I want to know the number of times that the value in column 2 appears as well as the corresponding values in column 1

So I'm trying to get this....

Col2,          No of times it Occurs,      Col1 values for col2
46798,        1,                    12
46799,        3,                    6692, 5710, 12                
46800,        3,                    6692, 5710, 12   
46805,        1,                    12

Many many thanks for any help...

for i in `awk -F, '{print $2|"uniq"}' infile`
do
echo "$i `grep -c $i infile`"
grep $i infile | awk '{print $1|"xargs"}'
done | paste - -
$> cat mach.ksh
awk '
     BEGIN{
          printf("%-10s%-10s%-30s\n","Col2","Count","Values")
     }
     {
          gsub(/,/,"",$1)
          a[$2]++
          b[$2]?b[$2]=b[$2] x $1:b[$2]=$1
     }
     END{
          for(x in a){
               printf("%-10s%-10s%-30s\n",x",",a[x]",",b[x])
          }
     }
' x=", " infile

Output:

$> ./mach.ksh
Col2      Count     Values
46798,    1,        12
46799,    3,        6692, 5710, 12
46800,    3,        6692, 5710, 12
46805,    1,        12
awk -F', +' 'END {
  for (k in v)
    print k, c[k], v[k]
  }
{
  v[$2] = $2 in v ? v[$2] ", " $1 : $1
  c[$2]++
   }' OFS=',\t' infile