cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Redshift bulk load

makeshwar
New Contributor II

Hi team,

Looking for a suggestion/enhancement to achieve the below senario. when i read a csv file (it might have \n\r (windows) & \n(unix) ). Who to fix this โ€ฆ

Today I read the file and when I do the bulk load using redshift bulk load snap and the data gets loaded with the \n\r . How can I escape these characters?

When i look at the properties of the snap , i could see the below. but itโ€™s not working.
image

1 ACCEPTED SOLUTION

makeshwar
New Contributor II

so โ€ฆ this gave me the solution

$content.contains(โ€˜\r\nโ€™)?
($content.replaceAll(โ€˜\r\nโ€™,โ€˜\nโ€™) && $content.replaceAll(โ€˜\nโ€™,โ€˜โ€™) ) : $content.replaceAll(โ€˜\nโ€™,โ€˜\nโ€™)

View solution in original post

5 REPLIES 5

makeshwar
New Contributor II

@koryknick Thanks for the suggestion โ€ฆ !! keeping this in y noteโ€ฆ!