Put file into volume within Databricks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Hi! From a Databricks job, i want to copy a workspace file into volume. how can i do that?
I tried
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Hi @lauraxyz,
You can give it a try using: dbutils.fs.cp("file:/Workspace/path/to/the/file", "/Volumes/path/to/destination")
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
by adding "file:", i'm able to put File type into Volume, but for Notebook type, i would get following error:
ExecutionError: An error occurred while calling o460.cp. : java.io.FileNotFoundException: /Workspace/path/to/the/file (Operation not supported)
How does it work for Notebook type of file? I tried replace "file:" with "notebook:" or "Notebook:", neither works
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
5 hours ago
Let me try it on my end and get back, looks like we need to upload the destination location to a dbfs location first then a volumen.