Discover this year's submissions to the Dataiku Frontrunner Awards and give kudos to your favorite use cases and success stories!READ MORE

how to move files from managed_folders to another

jdorgani
Level 1
how to move files from managed_folders to another

Hi everyone,

I am trying to move files from a managed_folders to another. In the managed folder's API documentation I see this function copy_to(targetwrite_mode='OVERWRITE'), but with this copies all the files when I only need to copy some. Is there a way to move the files without having to read them and then write them?

0 Kudos
1 Reply
AlexT
Dataiker
Dataiker

Hi @jdorgani ,

Have you tried using the merge folder recipe? 

https://doc.dataiku.com/dss/latest/connecting/managed_folders.html#merge-folder-recipe

This would do exactly what you are looking for. 

If you need the Python API, you can to iterate through the files and copy each of them. 

https://doc.dataiku.com/dss/latest/python-api/managed_folders.html#dataiku.Folder.list_paths_in_part...

 

Thanks 

0 Kudos