Re: [Maria-developers] [JIRA] (MDEV-11685) sql_mode can't be set with non-ascii connection charset
Hello Nirbhay, On 01/09/2017 09:48 PM, Nirbhay Choubey wrote:
Hi Bar,
On Mon, Jan 9, 2017 at 1:00 AM, Alexander Barkov <bar@mariadb.org <mailto:bar@mariadb.org>> wrote:
Hello Nirbhay,
IIRC, you was working on this issue. What is the current status?
Yes, I have just committed a patch. Could you please take a look at it?
The patch http://lists.askmonty.org/pipermail/commits/2017-January/010405.html looks Ok. I have a proposal for tests. The problem is that utf32, utf16 and ucs2 are not always compiled-in. So in case when some of the affected charsets is missing, sql_mode.test will fail. Can you please move the tests into ctype_utf32.test, ctype_utf16.test, ctype_ucs2.test ? I also suggest to add "SELECT @@sql_mode", to make sure that the assignment actually does what it's supposed to do. Remembering sql_mode is not necessary. It's OK to restore it to DEFAULT. Remembering character_set_connection is not necessary. It's Ok to do "SET NAMES utf8" at the end. Collecting all together, I'd suggest this chuck for ctype_utf32.test: --echo # --echo # MDEV-11685: sql_mode can't be set with non-ascii connection charset --echo # SET character_set_connection=utf32; SET sql_mode='NO_ENGINE_SUBSTITUTION'; SELECT @@sql_mode; SET sql_mode=DEFAULT; SET NAMES utf8; and similar chunks for ctype_utf16.test and ctype_ucs2.test. Thanks!
Best, Nirbhay
Thanks!
On 01/03/2017 09:31 PM, Elena Stepanova (JIRA) wrote: > > [ https://jira.mariadb.org/browse/MDEV-11685?page=com.atlassian.jira.plugin.sy... <https://jira.mariadb.org/browse/MDEV-11685?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel> ] > > Elena Stepanova reassigned MDEV-11685: > -------------------------------------- > > Labels: upstream (was: ) > Affects Version/s: 5.5 > 10.0 > 10.1 > 10.2 > Assignee: Alexander Barkov > >> sql_mode can't be set with non-ascii connection charset >> ------------------------------------------------------- >> >> Key: MDEV-11685 >> URL: https://jira.mariadb.org/browse/MDEV-11685 <https://jira.mariadb.org/browse/MDEV-11685> >> Project: MariaDB Server >> Issue Type: Bug >> Components: Character Sets >> Affects Versions: 10.2.3, 5.5, 10.0, 10.1, 10.2 >> Reporter: Nirbhay Choubey >> Assignee: Alexander Barkov >> Labels: upstream >> >> {code} >> MariaDB [test]> set sql_mode = 'NO_ENGINE_SUBSTITUTION'; >> Query OK, 0 rows affected (0.00 sec) >> MariaDB [test]> set character_set_connection=utf32; >> Query OK, 0 rows affected (0.00 sec) >> MariaDB [test]> set sql_mode = 'NO_ENGINE_SUBSTITUTION'; >> ERROR 1231 (42000): Variable 'sql_mode' can't be set to the value of 'NO_ENGINE_SUBSTITUTION' >> {code} > > > > -- > This message was sent by Atlassian JIRA > (v7.2.1#72003) >
Hi Bar, On Tue, Jan 10, 2017 at 2:41 AM, Alexander Barkov <bar@mariadb.org> wrote:
Hello Nirbhay,
On 01/09/2017 09:48 PM, Nirbhay Choubey wrote:
Hi Bar,
On Mon, Jan 9, 2017 at 1:00 AM, Alexander Barkov <bar@mariadb.org <mailto:bar@mariadb.org>> wrote:
Hello Nirbhay,
IIRC, you was working on this issue. What is the current status?
Yes, I have just committed a patch. Could you please take a look at it?
The patch http://lists.askmonty.org/pipermail/commits/2017-January/010405.html looks Ok.
I have a proposal for tests. The problem is that utf32, utf16 and ucs2 are not always compiled-in. So in case when some of the affected charsets is missing, sql_mode.test will fail.
Can you please move the tests into ctype_utf32.test, ctype_utf16.test, ctype_ucs2.test ?
I also suggest to add "SELECT @@sql_mode", to make sure that the assignment actually does what it's supposed to do.
Remembering sql_mode is not necessary. It's OK to restore it to DEFAULT. Remembering character_set_connection is not necessary. It's Ok to do "SET NAMES utf8" at the end.
Collecting all together, I'd suggest this chuck for ctype_utf32.test:
--echo # --echo # MDEV-11685: sql_mode can't be set with non-ascii connection charset --echo # SET character_set_connection=utf32; SET sql_mode='NO_ENGINE_SUBSTITUTION'; SELECT @@sql_mode; SET sql_mode=DEFAULT; SET NAMES utf8;
and similar chunks for ctype_utf16.test and ctype_ucs2.test.
Done. http://lists.askmonty.org/pipermail/commits/2017-January/010414.html Thanks for the review. Best, Nirbhay
Thanks!
Best, Nirbhay
Thanks!
On 01/03/2017 09:31 PM, Elena Stepanova (JIRA) wrote: > > [ https://jira.mariadb.org/browse/MDEV-11685?page=com.
atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
atlassian.jira.plugin.system.issuetabpanels:all-tabpanel>
] > > Elena Stepanova reassigned MDEV-11685: > -------------------------------------- > > Labels: upstream (was: ) > Affects Version/s: 5.5 > 10.0 > 10.1 > 10.2 > Assignee: Alexander Barkov > >> sql_mode can't be set with non-ascii connection charset >> ------------------------------------------------------- >> >> Key: MDEV-11685 >> URL: https://jira.mariadb.org/browse/MDEV-11685 <https://jira.mariadb.org/browse/MDEV-11685> >> Project: MariaDB Server >> Issue Type: Bug >> Components: Character Sets >> Affects Versions: 10.2.3, 5.5, 10.0, 10.1, 10.2 >> Reporter: Nirbhay Choubey >> Assignee: Alexander Barkov >> Labels: upstream >> >> {code} >> MariaDB [test]> set sql_mode = 'NO_ENGINE_SUBSTITUTION'; >> Query OK, 0 rows affected (0.00 sec) >> MariaDB [test]> set character_set_connection=utf32; >> Query OK, 0 rows affected (0.00 sec) >> MariaDB [test]> set sql_mode = 'NO_ENGINE_SUBSTITUTION'; >> ERROR 1231 (42000): Variable 'sql_mode' can't be set to the value of 'NO_ENGINE_SUBSTITUTION' >> {code} > > > > -- > This message was sent by Atlassian JIRA > (v7.2.1#72003) >
Hello Nirbhay, The patch looks fine. Just one note: can you please move the ucs2 related test from ctype_ucs2_def.test to ctype_ucs.test? The purpose of ctype_ucs_def.test is to cover that everything works fine with the ucs2 character set used as the default, i.e. when mysqld is started with --character-set-server=ucs2. MDEV-11685 is not relevant. Thanks! We should probably rename ctype_ucs.test to ctype_ucs2.test, it's name is confusing. On 01/10/2017 10:51 PM, Nirbhay Choubey wrote:
Hi Bar,
On Tue, Jan 10, 2017 at 2:41 AM, Alexander Barkov <bar@mariadb.org <mailto:bar@mariadb.org>> wrote:
Hello Nirbhay,
On 01/09/2017 09:48 PM, Nirbhay Choubey wrote: > Hi Bar, > > On Mon, Jan 9, 2017 at 1:00 AM, Alexander Barkov <bar@mariadb.org <mailto:bar@mariadb.org> > <mailto:bar@mariadb.org <mailto:bar@mariadb.org>>> wrote: > > Hello Nirbhay, > > IIRC, you was working on this issue. > What is the current status? > > > Yes, I have just committed a patch. > Could you please take a look at it?
The patch http://lists.askmonty.org/pipermail/commits/2017-January/010405.html <http://lists.askmonty.org/pipermail/commits/2017-January/010405.html> looks Ok.
I have a proposal for tests. The problem is that utf32, utf16 and ucs2 are not always compiled-in. So in case when some of the affected charsets is missing, sql_mode.test will fail.
Can you please move the tests into ctype_utf32.test, ctype_utf16.test, ctype_ucs2.test ?
I also suggest to add "SELECT @@sql_mode", to make sure that the assignment actually does what it's supposed to do.
Remembering sql_mode is not necessary. It's OK to restore it to DEFAULT. Remembering character_set_connection is not necessary. It's Ok to do "SET NAMES utf8" at the end.
Collecting all together, I'd suggest this chuck for ctype_utf32.test:
--echo # --echo # MDEV-11685: sql_mode can't be set with non-ascii connection charset --echo # SET character_set_connection=utf32; SET sql_mode='NO_ENGINE_SUBSTITUTION'; SELECT @@sql_mode; SET sql_mode=DEFAULT; SET NAMES utf8;
and similar chunks for ctype_utf16.test and ctype_ucs2.test.
Done.
http://lists.askmonty.org/pipermail/commits/2017-January/010414.html
Thanks for the review.
Best, Nirbhay
Thanks!
> > Best, > Nirbhay > > > > Thanks! > > On 01/03/2017 09:31 PM, Elena Stepanova (JIRA) wrote: > > > > [ > https://jira.mariadb.org/browse/MDEV-11685?page=com.atlassian.jira.plugin.sy... <https://jira.mariadb.org/browse/MDEV-11685?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel> > <https://jira.mariadb.org/browse/MDEV-11685?page=com.atlassian.jira.plugin.sy... <https://jira.mariadb.org/browse/MDEV-11685?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel>> > ] > > > > Elena Stepanova reassigned MDEV-11685: > > -------------------------------------- > > > > Labels: upstream (was: ) > > Affects Version/s: 5.5 > > 10.0 > > 10.1 > > 10.2 > > Assignee: Alexander Barkov > > > >> sql_mode can't be set with non-ascii connection charset > >> ------------------------------------------------------- > >> > >> Key: MDEV-11685 > >> URL: https://jira.mariadb.org/browse/MDEV-11685 <https://jira.mariadb.org/browse/MDEV-11685> > <https://jira.mariadb.org/browse/MDEV-11685 <https://jira.mariadb.org/browse/MDEV-11685>> > >> Project: MariaDB Server > >> Issue Type: Bug > >> Components: Character Sets > >> Affects Versions: 10.2.3, 5.5, 10.0, 10.1, 10.2 > >> Reporter: Nirbhay Choubey > >> Assignee: Alexander Barkov > >> Labels: upstream > >> > >> {code} > >> MariaDB [test]> set sql_mode = 'NO_ENGINE_SUBSTITUTION'; > >> Query OK, 0 rows affected (0.00 sec) > >> MariaDB [test]> set character_set_connection=utf32; > >> Query OK, 0 rows affected (0.00 sec) > >> MariaDB [test]> set sql_mode = 'NO_ENGINE_SUBSTITUTION'; > >> ERROR 1231 (42000): Variable 'sql_mode' can't be set to the value > of 'NO_ENGINE_SUBSTITUTION' > >> {code} > > > > > > > > -- > > This message was sent by Atlassian JIRA > > (v7.2.1#72003) > > > >
participants (2)
-
Alexander Barkov
-
Nirbhay Choubey