pyspark.sql.DataFrame.schema¶
-
property
DataFrame.schema¶ Returns the schema of this
DataFrameas apyspark.sql.types.StructType.New in version 1.3.0.
Examples
>>> df.schema StructType(List(StructField(age,IntegerType,true),StructField(name,StringType,true)))