DEFINER clause breaks replication
Bug #771572 reported by
Joe Daly
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Drizzle |
Fix Released
|
Critical
|
Joe Daly |
Bug Description
recent changes that added the access definer break replication, presumably this is missing something to allow this clause to be passed in
[New Thread 0x7fffdd2b5710 (LWP 25115)]
(SQLSTATE 00000) You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'DEFINER root' at line 1
Failure while executing:
COMMIT
CREATE SCHEMA `test1` COLLATE utf8_general_ci DEFINER root
UPDATE `sys_replicatio
Related branches
lp:~skinny.moey/drizzle/bug771572
- Brian Aker: Approve
-
Diff: 600 lines (+64/-57)26 files modifieddrizzled/message/statement_transform.cc (+4/-0)
drizzled/sql_yacc.yy (+5/-2)
plugin/collation_dictionary/tests/r/data_dictionary.result (+2/-2)
plugin/filtered_replicator/tests/r/var_filteredschemas.result (+1/-1)
plugin/filtered_replicator/tests/r/var_schemaregex.result (+1/-1)
plugin/information_schema_dictionary/tests/r/show_create_table.result (+20/-20)
plugin/innobase/tests/r/innodb_cmp.result (+1/-1)
plugin/innobase/tests/r/innodb_cmp_reset.result (+1/-1)
plugin/innobase/tests/r/innodb_cmpmem.result (+1/-1)
plugin/innobase/tests/r/innodb_cmpmem_reset.result (+1/-1)
plugin/innobase/tests/r/innodb_lock_waits.result (+1/-1)
plugin/innobase/tests/r/innodb_locks.result (+1/-1)
plugin/innobase/tests/r/innodb_replication_log.result (+1/-1)
plugin/innobase/tests/r/innodb_status.result (+1/-1)
plugin/innobase/tests/r/innodb_trx.result (+1/-1)
plugin/logging_stats/tests/r/command.result (+1/-1)
plugin/logging_stats/tests/r/max_user.result (+1/-1)
plugin/registry_dictionary/tests/r/data_dictionary.result (+2/-2)
plugin/replication_dictionary/tests/r/data_dictionary.result (+1/-1)
plugin/schema_dictionary/tests/r/data_dictionary.result (+6/-6)
plugin/session_dictionary/tests/r/data_dictionary.result (+1/-1)
plugin/status_dictionary/tests/r/data_dictionary.result (+4/-4)
plugin/table_cache_dictionary/tests/r/table_cache.result (+1/-1)
plugin/table_cache_dictionary/tests/r/table_definition_cache.result (+1/-1)
plugin/transaction_log/tests/r/schema.result (+2/-2)
tests/r/create.result (+2/-2)
Changed in drizzle: | |
status: | New → Confirmed |
importance: | Undecided → Critical |
Changed in drizzle: | |
assignee: | nobody → Joe Daly (skinny.moey) |
Changed in drizzle: | |
status: | Confirmed → Fix Committed |
Changed in drizzle: | |
status: | Fix Committed → Fix Released |
milestone: | none → 2011-05-09 |
To post a comment you must log in.
part of the problem is in transformCreate SchemaStatement ToSql() there are no quotes for DEFINER value. But another problem is that the parser seems to choke on having multiple definitions:
drizzle> CREATE SCHEMA `test4` DEFINER 'jdaly';
Query OK, 1 row affected (0.001228 sec)
drizzle> CREATE SCHEMA `test5` COLLATE utf8_general_ci;
Query OK, 1 row affected (0.001069 sec)
drizzle> CREATE SCHEMA `test6` COLLATE utf8_general_ci DEFINER 'jdaly';
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'DEFINER 'jdaly'' at line 1
drizzle>
The last statement is a combination of the first two, perhaps Im missing a secret identifier