0

Some field value contains 0x0D specail character The value from the hexdump:

4041000000000001D0534534534112342340000

But when I get the field value using isoMsg.getString(field_id), I got an equal sign instead of the 0x0D character

4041000000000001=0534534534112342340000

Is there any method to return the value as is without changing any control character data ?

apaderno
  • 28,547
  • 16
  • 75
  • 90
Muhammad Hewedy
  • 29,102
  • 44
  • 127
  • 219
  • Which datatype have you configured for the field? E.g. for BCD encoded fields, I assume that JPos may replace the invalid 'D' nibble with a replacement character like '='. – jarnbjo Dec 22 '09 at 20:57

2 Answers2

1

jPOS converts the 'D' into '=' on BCD fields using ISOUtil.bcd2str method.

This is useful to deal with track2 data.

You can easily replace it back.

apr
  • 1,288
  • 7
  • 8
0

Something's not right. You're looking at this:

4041000000000001D0534534534112342340000

This is 39 characters, or 19.5 bytes. Is this your issue?

John
  • 15,990
  • 10
  • 70
  • 110
  • It just doesn't make sense to interpret that string as character codes because you have half a character in that string. What about the fact that "D" is the only letter in that string? – John Dec 22 '09 at 20:18