Pacific-Design.com

    
Home Index

1. Spark

2. GroupBy

Spark / GroupBy /

Cassandra Context GroupBy


scala> csc.setKeyspace("engine")

scala> csc.sql("SELECT distinct domain, count(domain) total FROM health 
       GROUP BY domain 
       ORDER BY total DESC LIMIT 15").collect().foreach(println)

[sterlingpublishers.com,3976114]                                                
[mobydiskrecords.es,3023875]
[knubbelino.de,1400080]
[mobydiskrecords.com,1258286]
[academia.edu,855388]
[acwr.net,823951]
[twitter.com,753301]
[houzz.com,586607]
[fastbikebits.com,549021]
[iconosquare.com,543897]
[tumblr.com,508149]
[mensdesignerclothesonline.co.uk,486922]
[amarboi.org,479120]
[aliexpress.com,469176]
[lieju.com,462494]
[facebook.com,443447]
[tuniu.com,374308]