To fix this problem, the escape character reported by the driver can be overridden by setting a property in workbench. The backslash in the expression is the character reported by the driver, whereas the forward slash in the expression is the character actually used by the driver. However some older Oracle drivers report the wrong escape character, so the value sent to the database results in AND onwer LIKE 'USER\_1' ESCAPE '/'. the value USER\_1 if the driver reports that a backslash is used to escape wildcards. The character that is used to escape the wildcards is reported by the driver. The driver will create an expression similar to AND onwer LIKE 'USER_1' ESCAPE '\' (which would return tables for USERA1, USERB1 and so on, including of course USER_1). To avoid listing the objects for USERX1 when displaying the objects for USER_1 the underscore must be escaped. ![]() The driver calls used to display the list of tables and views in a specific schema expects a wildcard expression. Sean Newton This bug looks a lot like a bug in oracle workbench -> SELECT, INSERT, etc)Ĭorrectly account for underscores / prevent escaping. Select a database name containing an underscore (It will be escaped like "sample\_database") and press OK.ħ. ![]() Under the Schema section, choose "Selected schema:" optionĦ. Go to Users and Privileges, choose Schema Privileges tab, select a user.ĥ. Create a database with an underscore in the name (e.g. 'sample\database\name\here') Trying to add permissions to said database throws an SQL error: Error executing 'GRANT SELECT ON sample\table. The database name shows underscores 'escaped' (e.g. ![]() Trying to add permissions to said database throws an SQL error:Įrror executing 'GRANT SELECT ON sample\_table.* TO have an error in your SQL syntax check the manual that corresponds to your MySQL server version for the right syntax to useġ. Description: You can no longer assign schema privileges using the provided database list if the database name contains an underscore. They are: The percent sign () which represents zero, one, or multiple characters The underscore sign () represents one, single character. There are two wildcards that can be used in conjunction with the LIKE operator. The database name shows underscores "escaped" (e.g. The LIKE operator in SQL is used in a WHERE clause to search for a specified pattern in a column. You can no longer assign schema privileges using the provided database list if the database name contains an underscore.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |