Skip to content

Instantly share code, notes, and snippets.

@josep2
Created November 22, 2019 03:09
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 josep2/39ea5933997142ac15e61a7d28ff8c18 to your computer and use it in GitHub Desktop.
Save josep2/39ea5933997142ac15e61a7d28ff8c18 to your computer and use it in GitHub Desktop.
// from https://blog.codecentric.de/en/2016/07/spark-2-0-datasets-case-classes/
final case class Body(id: Int,
width: Double,
height: Double,
depth: Double,
material: String,
color: String)
val ds = df.as[Body]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment