.Net OracleClient and Oracle ZHT32EUC Character Set?


W

Wicky Hu

Hi,

My Oracle DB character set is ZHT32EUC.

When I use OracleClient to access the database, Traditional Chinese shown
wrong.
When I use OleDb, everything is ok.

And as I tested, OracleClient is ok for ZHS16GBK character set.

Anyone has any idea about it?

Thanks in advanced.

my testing code:

/***************************************/
//NLS_LANG set to American_America.ZHT32EUC

//dataGrid1 show wrong data for Traditional Chinese, only see blank block in
datagrid
OracleConnection cn1 = new OracleConnection(myConnectionString1);
OracleDataAdapter da1 = new OracleDataAdapter(sql,cn1);
DataSet ds1 =new DataSet();
da1.Fill(ds1);
dataGrid1.DataSource = ds1.Tables[0].DefaultView;


//dataGrid2 show correct data for Traditional Chinese
OleDbConnection cn2 = new OleDbConnection(myConnectionString2);
OleDbDataAdapter da2 = new OleDbDataAdapter(sql,cn2);
DataSet ds2 =new DataSet();
da2.Fill(ds2);
dataGrid2.DataSource = ds2.Tables[0].DefaultView;
/***************************************/


Regards
Wicky Hu
 
Ad

Advertisements


Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top