This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | [65cat] Unable to create or delete tables in MySQL support with names that need quoting | ||
---|---|---|---|
Product: | db | Reporter: | sunbiz <sunbiz> |
Component: | Code | Assignee: | David Vancouvering <davidvc> |
Status: | VERIFIED FIXED | ||
Severity: | blocker | CC: | sustaining |
Priority: | P2 | ||
Version: | 6.x | ||
Hardware: | All | ||
OS: | All | ||
URL: | http://statistics.netbeans.org/exceptions/detail.do?id=135040 | ||
Issue Type: | DEFECT | Exception Reporter: | 135040 |
Attachments: | stacktrace |
Description
sunbiz
2008-11-01 20:55:56 UTC
Created attachment 73056 [details]
stacktrace
I can reproduce this by trying to create a database with the "*" character in it. Such a database name needs to be quoted. MySQL using the backtick character (`) for quoting, see http://dev.mysql.com/doc/refman/5.0/en/identifiers.html. When I backtick the *, the database is created correctly. However, the database connection for this database that we create automatically causes an error, as we directly translate the backticks to the JDBC URL, and MySQL can't find the database `*`. This basically means this functionality is broken for database names that have characters that must be quoted (particularly multibyte characters). I tested with 前空幕長が会見 (a string of characters I got from http://www.yahoo.jp) and I got the same problem. Since this breaks international support, it's a P2, and I'm copying Ken Frank, our I18N guy. It would be nice if we detect that the string needs to be quoted and quote it, but at a minimum we should correctly support quoting. Note: we also need to fix *deleting* databases that have characters that need quoting. Right now this fails with a syntax exception. 8103d60a32dd Used the very nice Quoter API. Made it very easy to fix this. Thanks to whoever wrote this API (oh, wait, it was me! :)). Now you can use multibyte or other characters in your db name that need quoting, and you can both create and delete the databases. Integrated into 'main-golden', will be available in build *200811041401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/8103d60a32dd User: David Van Couvering <davidvc@netbeans.org> Log: #152107: [65cat] Unable to create or delete tables in MySQL support with names that need quoting *** Issue 152448 has been marked as a duplicate of this issue. *** Issue 152448 is fixed as a duplicate, removing it as a depending item. I just tested 'test*1' in my sandbox and it works, please verify. Verified with build 081107. I've ported the changeset http://hg.netbeans.org/main/rev/8103d60a32dd into release65_fixes repository as http://hg.netbeans.org/release65_fixes/rev/13744aebb76d |