cancel
Showing results for 
Search instead for 
Did you mean: 

Null characters in the source file

former_member203631
Participant
0 Kudos

Hi frnds,

We have a file to file scenario, where in R/3 system will generate the flat files and put in the some folder of R/3 system itself. XI needs to pick this file and process but the problem here is the file contains every alternate character as null character i.e., 1st,3rd,5th.. and so on. Whic is failing during mapping.

Following is the error message displayed:

*com.sap.aii.utilxi.misc.api.BaseRuntimeException: Fatal Error: com.sap.engine.lib.xml.parser.ParserException: Invalid char #0x0(:main:, row:4, col:12) at java.lang.Throwable.<init>(Throwable.java:56) at com.sap.aii.utilxi.misc.api.BaseRuntimeException.<init>(BaseRuntimeException.java:58) at com.sap.aii.mappingtool.tf3.Transformer.checkParserException(Transformer.java:187) at com.sap.aii.mappingtool.tf3.Transformer.start(Transformer.java:174) at com.sap.aii.mappingtool.tf3.AMappingProgram.execute(AMappingProgram.java:105) at com.sap.aii.ibrun.server.mapping.JavaMapping.executeStep(JavaMapping.java:64) at com.sap.aii.ibrun.server.mapping.Mapping.execute(Mapping.java:92) at com.sap.aii.ibrun.server.mapping.MappingHandler.run(MappingHandler.java:90) at com.sap.aii.ibrun.sbeans.mapping.MappingRequestHandler.handleMappingRequest(MappingRequestHandler.java:95) a.............t *

Please can any one help how to handle this file with null characters.

Regards,

Shiva.

Accepted Solutions (0)

Answers (3)

Answers (3)

stefan_grube
Active Contributor
0 Kudos

I suppose that your file is UTF-16.

Apply UTF-16 as encoding in the file adapter channel.

Regards

Stefan

Former Member
0 Kudos

Hi,

u can try by using UDF.

In UDF u can handle Null value.

Before using UDF 1st try by using RemoveContext function.

Regards,

Rohit

Reward points if helpful.

Former Member
0 Kudos

HI,

On source side make all those fields as optional i.e. occurance will be 0..1 or 0...Unbounded.

Also while mapping with Receiver fields make those also optional or use DefaultValue Node to pass default value as blank space.

Actually the node is unable to generate due to Null value so that might be the problem

Thanks

Swarup