• Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » How to eliminate new line character in XML file

#1 2012-03-28 08:31:33

Vikram
Guest

How to eliminate new line character in XML file

i am creating a XML file , based on join of two tables .
Some times there is extra blank space or new line character in DB , how do i treat it ?

EX: Due to the new line character XML file line is

<L1>Jasper
ETL</L1>

Result should be :  <L1>Jasper ETL</L1>

#2 2012-03-28 08:37:47

pedro
Member
Registered: 2011-11-17
Posts: 3682

Re: How to eliminate new line character in XML file

Hi

You can use tReplace before XML output component to replace extra blank space with double quotation marks(e.g. "") and replace "\n" with double quotation marks(e.g. "").

Regards,
Pedro


Uploaded Images


Only Paranoid Survive.

Offline

#3 2012-03-28 10:07:27

janhess
Member
Company: Newcastle University
Registered: 2009-05-19
Posts: 1137

Re: How to eliminate new line character in XML file

You may need to replace \r as well.

Offline

#4 2012-03-29 08:58:59

Vikram
Guest

Re: How to eliminate new line character in XML file

Hi Pedro and Janhess,

Thanks for the suggestions , Appreciate your help !! :)

Tired your solution , it worked :)

  • Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » How to eliminate new line character in XML file

Board footer

Powered by FluxBB