#330 Mapping Error in Cp437

Connection
open
wanghuiq
None
5
2014-07-22
2011-05-30
unxi53
No

In ccsid 437 the charater \u00B5 ('µ') is not mapped correctly by AS400Text.

When I do a round trip mapping with ccsid 437 (String -> AS400Text ->byte[] -> AS400Text -> String) the µ caracter goes amiss. It is part of the Cp437 though.

Peer

Discussion

  • John Eberhard

    John Eberhard - 2011-09-30
    • status: open --> pending
     
  • John Eberhard

    John Eberhard - 2011-09-30

    Please provide more details. Do you have a sample program?

     
  • John Eberhard

    John Eberhard - 2011-09-30
    • assigned_to: nobody --> piguangming
     
  • unxi53

    unxi53 - 2011-09-30

    You are kidding me, right?

    import com.ibm.as400.access.AS400Text;
    public class Test {
    public static void main(String[] args) {
    String s1 = "\u00B5";
    System.out.println(s1);
    AS400Text txt = new AS400Text(1, 437);
    byte[] b = txt.toBytes(s1);
    String s2 = (String) txt.toObject(b);
    System.out.println(s2);
    }
    }

     
  • unxi53

    unxi53 - 2011-09-30
    • assigned_to: piguangming --> nobody
    • status: pending --> open
     
  • John Eberhard

    John Eberhard - 2012-06-11
    • assigned_to: nobody --> piguangming
     
  • John Eberhard

    John Eberhard - 2014-07-22
    • assigned_to: GuangMing Pi --> wanghuiq
    • Group: --> Connection
     

Log in to post a comment.