snowflake.snowpark.DataFrame.printSchema¶
- DataFrame.printSchema(level: Optional[int] = None) None [source] (https://github.com/snowflakedb/snowpark-python/blob/v1.30.0/snowpark-python/src/snowflake/snowpark/dataframe.py#L6270-L6284)¶
Prints the schema of a dataframe in tree format.
- Parameters:
level – The level to print to for nested schemas.
- Examples::
>>> df = session.create_dataframe([(1, "a"), (2, "b")], schema=["a", "b"]) >>> df.print_schema() root |-- "A": LongType() (nullable = False) |-- "B": StringType() (nullable = False)