Export dataset to folder recipe newline options
Hello,
I currently have an export to folder recipe taking a dataset and dumping it as a CSV to a folder for some automation purposes. The CSV created uses the Unix-style newline (LF) formats. Our customer receiving this file inquired if they could get it using the Windows-style instead (CRLF). I poked around the options for the recipe and it seemed like any export format options other than delimiter were non-existent (attached an image of what I am seeing). I am wondering if I am missing where this is configured?
My plan B is to open the file up after the fact and just convert it using a python script or something but wanted to see if there is an option I am missing in DSS first.
Any help or advice would be much appreciated!
Operating system used: Linux
Answers
-
Alexandru Dataiker, Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 1,212 Dataiker
Hi,
Indeed this is not configurable in DSS export to folder recipe. You can use a Python recipe instead. Various method to do this including in pandas :
df.to_csv(output_file, index=False, line_terminator='\r\n')
Then you can write the file to the managed folder directly.
https://doc.dataiku.com/dss/latest/python-api/managed_folders.html#dataikuapi.dss.managedfolder.DSSManagedFolder.put_fileThanks,