Skip to content

Instantly share code, notes, and snippets.

@brianmhess
Created March 30, 2015 21:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brianmhess/08a4e776856f657842de to your computer and use it in GitHub Desktop.
Save brianmhess/08a4e776856f657842de to your computer and use it in GitHub Desktop.
sc.textFile("/mnt/disk2/data/data_99-rand.csv").map(x => x.split(",")).map(x => (x(0).toLong, x(1).toLong, x(2).toLong, x(3).toLong, x(4).toLong, x(5).toLong, x(6).toLong, x(7).toLong, x(8).toLong, x(9).toLong)).saveToCassandra("test", "test10", SomeColumns("pkey", "ccol", "col1", "col2", "col3", "col4", "col5", "col6", "col7", "col8"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment