[MDEV-13504] CONNECT engine table_type=JDBC with UPDATE of NCAHR, NVARCHAR columns not working Created: 2017-08-11 Updated: 2017-10-13 |
|
| Status: | Open |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - Connect |
| Affects Version/s: | 10.1.26 |
| Fix Version/s: | 10.1 |
| Type: | Bug | Priority: | Major |
| Reporter: | Robert Dyas | Assignee: | Olivier Bertrand |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Centos7 |
||
| Description |
|
With 10.1.26 and a Microsoft JDBC driver, the NCHAR and NVARCHAR column types do correctly INSERT foreign characters (INSERT AND SELECT both produce correct values). However with an UPDATE statement the data comes through as ??? rather than the actual characters. |
| Comments |
| Comment by Robert Dyas [ 2017-08-15 ] | |||||||
|
Hi Olivier, Have you had a chance to look into this? | |||||||
| Comment by Olivier Bertrand [ 2017-08-16 ] | |||||||
|
I just updated the mytest and myntext columns of the all_types table. Apparently it worked whether or not the DATA_CHARSET option is set to UTF8 (it was set to utf8 when I updated line 6 and to latin1 when updating line 7) However, the table is displayed correctly only with DATA_CHARSET=utf8. | |||||||
| Comment by Robert Dyas [ 2017-08-16 ] | |||||||
|
I'm not sure I follow that.... In 10.1.26:
I'm guessing there is something different about how you encode INSERT vs. UPDATE statements (seem to remember this from an earlier discussion). | |||||||
| Comment by Olivier Bertrand [ 2017-08-16 ] | |||||||
|
The version I am using may contain some fixes not yet distributed but I am not sure what they could be. But if yours correctly displays Nchars columns, it probably have the same fixes. When I tried:
They both failed with the message:
So I did:
And it worked and displayed the line 7 (but requires DATA_CHARSET=utf8) Perhaps is there errors specific to some charsets (like Thai) | |||||||
| Comment by Robert Dyas [ 2017-08-16 ] | |||||||
|
Regarding:
That makes sense to me. It is a MS SQL SERVER limitation I'm guessing. Regarding:
Funny, that works for me too. Both the UPDATE and the SELECT work correctly. So it must only be an issue with more exotic characters like Thai/Arabic/Kanji? |