cancel
Showing results for 
Search instead for 
Did you mean: 

Reading a UTF-8 File with BOM (Byte Order Mark) with the File Adapter

Former Member
0 Kudos

Hello,

i try to read a UTF-8 with BOM with the file adapter.

The first line in the file looks like that:

20080911B189006 000000000000018203 ST 5.000 eqpjlqk 0001weber 795184000010

in hex:

EFBBBF3230303830393131423138393030362030303030303030303030303030313832303320202020202020535420202020202020202020202020202020352E30303020206571706A6C716B2020202030303031776562657220202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202037393531383430303030313020202020

Where EFBBBF are the 3 Charakters from the BOM.

My Payload after reading looks like that:

?2008091

The first character in the payload is a '?' and the whole line is shifted by 1 character.

Can anyone help my to get this problem solved?

Thanks

Matthias

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Thanks a lot. I was reading the german wikipedia entry about the BOM and there it is not as clear as in the english wikipedia entry.

stefan_grube
Active Contributor
0 Kudos

This is not a BOM - it is a Windows UTF-8 identifier.

You should avoid creating UTF-8 files with Windows Notepad. This identifier is non-standard and not supported by Unix systems.

If you want to test the content conversion, do not use UTF-8 files or choose another editor program.

Regards

Stefan

stefan_grube
Active Contributor
0 Kudos

PS: Wikipedia knows everything

http://en.wikipedia.org/wiki/Byte-order_mark

bhavesh_kantilal
Active Contributor
0 Kudos

Can you try to find the codepage of the system which created the File and then try to use the corresponding Codepage in the file adapter?

Check the how to guide for more info,

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/502991a2-45d9-2910-d99f-8aba5d79...

Regards

Bhavesh

Former Member
0 Kudos

Anyone any Idea?