Author |
Message
|
giorginus80 |
Posted: Tue Dec 23, 2008 2:40 am Post subject: Insert DB mapping special character |
|
|
 Centurion
Joined: 08 Jul 2008 Posts: 124 Location: Rome, Italy
|
Hi, I have a problem when inserting with a map in the db Oracle. Everythings works ok, I have my message mapped in the columns of DB, but I had a record which has special character in this case is ° and when inserting it put dirty field in db, so when I try to select and recover the data I have an exception 'Unconvertable character'. I tryed to write the special character with hand in the column, and if you write it, the column accept it without problem, so why the broker when insert the column with the map, put it dirty?
I have Broker 6.1.0.3 on linux and I tried setting MQSI_LOCAL_CCSID=819 in my environment but with no result, the field it's dirty. |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Dec 23, 2008 6:58 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
You did not specify the version of Oracle. Assuming you are on 10g and running with UTF-8 i.e. CCSID 1208 why are you trying to use CCSID 819 which does not support the full character set. Maybe that is why you have a "dirty" char in your DB. When using CCSID 819 conversion, some characters do not convert. This may be the case you are facing.
Have fun  _________________ MQ & Broker admin |
|
Back to top |
|
 |
giorginus80 |
Posted: Tue Dec 23, 2008 7:00 am Post subject: |
|
|
 Centurion
Joined: 08 Jul 2008 Posts: 124 Location: Rome, Italy
|
fjb_saper wrote: |
You did not specify the version of Oracle. Assuming you are on 10g and running with UTF-8 i.e. CCSID 1208 why are you trying to use CCSID 819 which does not support the full character set. Maybe that is why you have a "dirty" char in your DB. When using CCSID 819 conversion, some characters do not convert. This may be the case you are facing.
Have fun  |
I have oracle 9.2.0.1, This happens with CCSID set in ev or without CCSID. What can I do? |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Dec 23, 2008 7:32 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
giorginus80 wrote: |
fjb_saper wrote: |
You did not specify the version of Oracle. Assuming you are on 10g and running with UTF-8 i.e. CCSID 1208 why are you trying to use CCSID 819 which does not support the full character set. Maybe that is why you have a "dirty" char in your DB. When using CCSID 819 conversion, some characters do not convert. This may be the case you are facing.
Have fun  |
I have oracle 9.2.0.1, This happens with CCSID set in ev or without CCSID. What can I do? |
If your DB is not UTF-8 you need to check that the char is in the range of those accepted by the DB (beware there are some graphical chars that look like chars but are not translatable to a single byte charset check hex values).
If you want to keep all the chars you might have to store as a blob in the DB.
Have fun  _________________ MQ & Broker admin |
|
Back to top |
|
 |
giorginus80 |
Posted: Tue Dec 23, 2008 7:36 am Post subject: |
|
|
 Centurion
Joined: 08 Jul 2008 Posts: 124 Location: Rome, Italy
|
fjb_saper wrote: |
giorginus80 wrote: |
fjb_saper wrote: |
You did not specify the version of Oracle. Assuming you are on 10g and running with UTF-8 i.e. CCSID 1208 why are you trying to use CCSID 819 which does not support the full character set. Maybe that is why you have a "dirty" char in your DB. When using CCSID 819 conversion, some characters do not convert. This may be the case you are facing.
Have fun  |
I have oracle 9.2.0.1, This happens with CCSID set in ev or without CCSID. What can I do? |
If your DB is not UTF-8 you need to check that the char is in the range of those accepted by the DB (beware there are some graphical chars that look like chars but are not translatable to a single byte charset check hex values).
If you want to keep all the chars you might have to store as a blob in the DB.
Have fun  |
But the db is utf-8, if I write in manually with TOAD client, I can write the right character in the column. |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Dec 23, 2008 7:48 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
giorginus80 wrote: |
But the db is utf-8, if I write in manually with TOAD client, I can write the right character in the column. |
Now the plot thickens. Are you making sure the connection to the DB and the data sent over the connection is UTF-8 ?
You might have to change the lang environment var for the process the broker runs in to be UTF-8 or equivalent.  _________________ MQ & Broker admin |
|
Back to top |
|
 |
giorginus80 |
Posted: Tue Dec 23, 2008 7:50 am Post subject: |
|
|
 Centurion
Joined: 08 Jul 2008 Posts: 124 Location: Rome, Italy
|
fjb_saper wrote: |
giorginus80 wrote: |
But the db is utf-8, if I write in manually with TOAD client, I can write the right character in the column. |
Now the plot thickens. Are you making sure the connection to the DB and the data sent over the connection is UTF-8 ?
You might have to change the lang environment var for the process the broker runs in to be UTF-8 or equivalent.  |
How can I do it? Broker is in linux environment, Oracle in Windows Environment |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Dec 23, 2008 9:08 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
In the Linux environment make sure you install UTF-8 charset.
Make sure your environment vars point to the UTF-8 charset and not 819.
Start the broker from that environment.
Make sure the data you pass to the oracle connection is UTF-8 (ccsid 1208)
Have fun  _________________ MQ & Broker admin |
|
Back to top |
|
 |
giorginus80 |
Posted: Tue Dec 23, 2008 9:19 am Post subject: |
|
|
 Centurion
Joined: 08 Jul 2008 Posts: 124 Location: Rome, Italy
|
fjb_saper wrote: |
In the Linux environment make sure you install UTF-8 charset.
Make sure your environment vars point to the UTF-8 charset and not 819.
Start the broker from that environment.
Make sure the data you pass to the oracle connection is UTF-8 (ccsid 1208)
Have fun  |
Thanks it works |
|
Back to top |
|
 |
|