Page 1 of 1

Replace Linefeed Characters coming from the source with null

Posted: Mon Nov 17, 2008 3:18 am
by prasad_chennai
Hi All,

I have a simple datastage job where I am extracting the data from a table and I am creating a flat file(text file). These flat files are used to generate reports. But I am getting linefeeds embedded with some of the values coming from certain columns. How can I replace these linefeeds with a null value.

Thanks,
Prasad

Posted: Mon Nov 17, 2008 5:25 am
by ray.wurlod

Code: Select all

Convert(svLF, "", InLink.TheString)
You do not want to convert to NULL, you want to convert to zero-length string.
Initialize stage variable svLF to Char(10) and do not supply a per-row derivation expression.