cancel
Showing results for 
Search instead for 
Did you mean: 

REGARDING CONTENT CONVERSION IN SENDER SIDE

Former Member
0 Kudos

Hi

I have a flat file like this

column names NO NAME AGE

FLAT FILE IS 1#KIRAN#27

2###28

3#RAVI#28

in the second record the name field is also filled with #

so please tell me how can we handle this

thanks&regards

venkat

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Venkat ,

Use .fieldFixedLengths option if lenth is always unique,

If not you have to go for UDF..as i Know.

If you made a specification for .fieldFixedLengths, the length of the separator is not taken into account.

You must specify at least either NameA.fieldFixedLengths or NameA.fieldSeparator.

If you have only specified .fieldSeparator, the structures of the XML document can have differing numbers of elements that are added to each other separately in the text file by the value from .fieldSeparator. If you specify .fieldFixedLengths this is not possible since the number of columns is defined when the column widths are given.

BestRegards,

Ramesh.

Answers (1)

Answers (1)

sunil_singh13
Active Contributor
0 Kudos

Hi Venky ,

I think you have to go for UDF in that calculate the length of characters between first and last "#" and replace all the "#" present in that substring with some other character like "!@!" do the content conversion and then again use another UDF in that replace all "!@!" with "#" and then send the file to required destination .

reward Points if helpful

Thanks

Sunil SIngh