RE: Replication Bug with underscore
"Brian Piere" <[email protected]>
| Newsgroups | gmane.comp.db.mysql.bugs |
|---|---|
| Message-ID | <[email protected]> |
I am using... Ver 4.0.15-standard for pc-linux on i686 The same version is running on both the master and the slave. This statment gives an errror GRANT ALL ON `printsma\_prints`.* TO 'printsma_brian'@'localhost'; ERROR 1133: Can't find any matching row in the user table This one works GRANT ALL ON `printsma\_prints`.* TO 'printsma\_brian'@'localhost' This is part of the "user" and "host" list within the "mysql" DB | printsma | localhost | | printsma\_brian | localhost | | printsma_brian | localhost | | printsma_worldsh | localhost | | riadmin | localhost | So something funny with the backslash happened there, ... I did not put it there, the replication software did. Just to give you a brief background... I have 2 dedicated servers setup and this server has my slave running on it. I made a mistake setting up the binary log on the master. I forgot to use the switch "binlog-do-db=" ... So the binary log was recording everything. Those grant statements should never have been run on the slave. The problem is fixed now, but I just wanted to let you guys know because something seems fishy with it. Thanks for your quick reply. I am grateful to use MySQL! ~Brian -----Original Message----- From: Paul DuBois [mailto:[email protected]] Sent: Wednesday, November 26, 2003 9:11 AM To: Brian Piere; [email protected] Subject: Re: Replication Bug with underscore At 2:15 -0800 11/26/03, Brian Piere wrote: >When I run SHOW SLAVE STATUS I get the following error.... > >----------------- >n.005 | 35671 | plain-relay-bin.003 | 12158086 | >server-bin. >003 | Yes | No | | > | 1133 | Error 'Can't find any matching row in the user >table' o >n query 'GRANT ALL ON `printsma\_prints`.* TO 'printsma_brian'@'localhost''. >Def >ault database: 'mysql' | 0 | 14366122 | 540788708 >------------------- > >The reason the query is failing is because my user name has an underscore in >it. The following query works... >GRANT ALL ON `printsma\_prints`.* TO 'printsma\_brian'@'localhost' > >It looks like you are escaping the underscore within the database name but >not within the user name. I suspect that is not the problem. Wildcard characters are special in host and database names, but not in usernames. '_' doesn't need to be escaped in a username. Granting privileges to a username of 'printsma_brian' is different than granting privileges to a username of 'printsma\_brian'. At least, I just tried this both ways on 4.0.14, and I end up with separate lines in the grant tables. I also end up with distinct output for both names when I use SHOW GRANTS. Do you have a case where you specify \_ in the GRANT but don't get it in the output of SHOW GRANTS, or where you specify _ in the grant but don't get it in the output of SHOW GRANTS? > >Thanks for looking into it >~Brian > > >-- >MySQL Bugs Mailing List >For list archives: http://lists.mysql.com/bugs >To unsubscribe: http://lists.mysql.com/[email protected] -- Paul DuBois, Senior Technical Writer Madison, Wisconsin, USA MySQL AB, www.mysql.com Are you MySQL certified? http://www.mysql.com/certification/ -- MySQL Bugs Mailing List For list archives: http://lists.mysql.com/bugs To unsubscribe: http://lists.mysql.com/[email protected]