Last active
April 16, 2020 07:12
-
-
Save visualskyrim/ad03e83584292b20f4ca6ccd3e9a9a88 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case class InputData(...) | |
val dataSchema = | |
ScalaReflection.schemaFor[InputData].dataType.asInstanceOf[StructType] | |
val dataset: Dataset[InputData] = spark | |
.read | |
.schema(dataSchema) | |
.parquet(incomingPath) | |
.as[InputData] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment