问题
I have a simple requirement where i have to write a csv to linux sftp . In the current implementation Which I have done CR-'carriage return' is being removed when writting the csv to sftp using mulesoft sftp connector . I have set encoding=US-ASCII on the sftp connector , in the dataweave , even in the property file as mule.encoding=US-ASCII. Nothing seems like working in cloud hub , but surprisingly the same works fine in my local . I understand after reading few blogs/ white papers that trasfer type should be 'ASCII' when writing to Linux SFTP . This is clearly an issue with cloudHub I believe . Any help is much appreciated .
回答1:
Explicitly setting %output application/csv lineSeparator="\r\n" worked for me. Thanks
来源:https://stackoverflow.com/questions/47201533/issue-writing-file-to-sftp-carriage-return-removed