Ultimate Collection - { fslBlog & faisalmb.com } Ultimate Collection - { fslBlog & faisalmb.com }   
Blog   |   Site   |   Posts (326)   |   Tags Xplorer   |   Feed Subscribe Free! Aha! you surfing post Accessing JD Edwards Data... Sign in    Partner Site - Real Home Contact Search   

Thu

28

Jan

2010

   

Accessing JD Edwards Data on iSeries or AS/400 from a ASP.NET / SQL Encoding / Error problem



Accessing JD Edwards Data on iSeries or AS/400 from a ASP.NET

Facing problem, while retrieving field data from JD Edwards to SQL (SSRS Reporting), giving Error or Special unicode characters,
because, the returning data was a stream that needs to be converted into ASCII (ebcdic37String) using Cp037 Encoding.


public static String convertEBCDIC37ToUnicode(String ebcdic37String)
{
 String encoding = "Cp037";
 byte[] ebcdic;
 String converted = null;
 try
 {
  ebcdic = ebcdic37String.getBytes();
  converted = new String( ebcdic, encoding );
 }
 catch (Exception e)
 {
  //Handle it
 }
 return converted;
}

 

Tags: , , ,

Categories : Computers / Programming / Mobiles


Add Comment Add comment

 
 
 
   Country flag

biuquote
  • Comment
  • Preview
Loading





Intro

Faisal Bashir
Software Architect
KalSoft Limited
Microsoft Certified Technology Specialist.
Currently in Dubai. [more]

Recent Comments

Comment RSS

Calendar

<<  March 2010  >>
MoTuWeThFrSaSu
22232425262728
1234567
891011121314
15161718192021
22232425262728
2930311234

View posts in large calendar

If you hear the call to prayer, then respond to the one who is calling you to Allah.
210373 hits. (Best viewed @ 1024x768 resolution min.) Comments here...
© 2001-2009 Muhammad Faisal | Disclaimer | Contact | Partner Site