cancel
Showing results for 
Search instead for 
Did you mean: 

HCI csv converter, remove blank line between headers and elements

Former Member
0 Kudos

I added to the XSLT Mapping file a customize header, example:

<Records>

<Header>

<H1>Customize Header</H1>

</Header>

<Elements>

<Value1>Value 1</Value1>

</Elements>

</Records>

But when i use the XML to CSV converter the iflow gives me a .csv file with a blank line between the header (Customize Header) and the elements (Value1).

CSV File output:

Customize Header

------Blank line-----

Value 1

Is there a way to remove the blank line?

Regards,

Former Member
0 Kudos

I already resolved this issue i put an script after the xml to csv converter with this code:

import com.sap.gateway.ip.core.customdev.util.Message;

import java.util.HashMap;

def Message processData(Message message) {

def body = message.getBody(String.class);

body = body.replaceAll("[\n]","");

message.setBody(body);

return message;

}

Kind Regards,

Accepted Solutions (0)

Answers (0)