snowflake.snowpark.FileOperation¶
- class snowflake.snowpark.FileOperation(session: Session)[source]¶
Bases:
object
Provides methods for working on files in a stage. To access an object of this class, use
Session.file
.Methods
copy_files
(source, target_stage_location, *)Copy files from a source location to an output stage.
get
(stage_location, target_directory, *[, ...])Downloads the specified files from a path in a stage to a local directory.
get_stream
(stage_location, *[, parallel, ...])Downloads the specified files from a path in a stage and expose it through a stream.
list
(stage_location, *[, pattern, ...])Returns a list of files from a stage.
put
(local_file_name, stage_location, *[, ...])Uploads local files to the stage.
put_stream
(input_stream, stage_location, *)Uploads local files to the stage via a file stream.
remove
(stage_location, *[, pattern, ...])Removes files from a stage.