managed folder with multiple dataframes

ltounsi
Level 1
managed folder with multiple dataframes

hello 

i have a python recipe with multiple data frames as output i would like to know how to put all these output into one managed folder. 

 

regards.

0 Kudos
2 Replies
Turribeach

The following Python code in a Python recipe will output the contents of the df dataframe to a CSV file:

import dataiku

path_upload_file = "output.csv"
handle = dataiku.Folder("Some Managed Folder")

with handle.get_writer(path_upload_file) as w:
    w.write(df.to_csv().encode('utf-8'))

 

 

0 Kudos
Turribeach

You can also use the Export to Folder visual recipe but that only allows to write back a single output at a time. 

0 Kudos