snowflake.snowpark.DataFrameReader.directory

DataFrameReader.directory(stage_name: str) DataFrame[source] (https://github.com/snowflakedb/snowpark-python/blob/v1.39.1/src/snowflake/snowpark/dataframe_reader.py#L2091-L2125)

Returns a DataFrame representing the results of a directory table query on the specified stage.

This method is an alias of directory().

Parameters:

stage_name – The name of the stage to query. The stage name should not include the ‘@’ prefix as it will be added automatically.

Returns:

  • RELATIVE_PATH: Path to the files to access using the file URL

  • SIZE: Size of the file in bytes

  • LAST_MODIFIED: Timestamp when the file was last updated in the stage

  • MD5: MD5 checksum for the file

  • ETAG: ETag header for the file

  • FILE_URL: Snowflake file URL to access the file

Return type:

A DataFrame containing metadata about files in the stage with the following columns

语言: 中文