Given a SchemaRDD
(loaded using SQLContext.parquetFile
), how do I extract its metadata/schema/list of columns?
The field list is accessible through the SchemaRDD
as [rdd].schema.fields
.
lazy val schema: StructType Returns the schema of this SchemaRDD (represented by a StructType).