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.

Bug 129945 - Creata database for MySQL error message shows key instead of message
Summary: Creata database for MySQL error message shows key instead of message
Status: VERIFIED FIXED
Alias: None
Product: db
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: David Vancouvering
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-03-12 18:00 UTC by Roman Mostyka
Modified: 2008-03-25 14:18 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Roman Mostyka 2008-03-12 18:00:59 UTC
1. Register MySQL DB server:
Host name: jbrave-pc1.sfbay.sun.com
Port: 3306
User name: travel
Password: travel
2. Rightclick "MySQL Server" node and choose "Create Database".
3. Select "sample" and click OK.

Result: Error message appears, but it isn't informative.
Comment 1 David Vancouvering 2008-03-12 18:28:03 UTC
Hi, Roman, but can you please tell me what the error message is?  I do this all the time and it works fine for me.
Comment 2 Roman Mostyka 2008-03-12 18:43:47 UTC
"CreateDatabasePanel.MSG_CreateFailed: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Access denied for user
'travel'@'%' to database 'sample'".
Comment 3 David Vancouvering 2008-03-12 20:02:06 UTC
Ah.  This message is coming from MySQL.  I'm not sure why you don't think it's informative.  It says right there "Access
denied".  It is one of any number of messages that could potentially come from MySQL.  I think it's better to provide
the message as received from the server, rather than try and provide our own message.  This transparency will allow
users to, for instance, Google for the error message and find useful support from the MySQL community.

I'm happy to discuss this, but I think this is actually the correct behavior if you try to create a database when you
don't have rights to create a database.
Comment 4 David Vancouvering 2008-03-12 20:20:32 UTC
Reopening after looking at the error message again: it seems to be showing the key for the message
("CreateDatabasePanel.MSG_CreateFailed") rather than the message itself.
Comment 5 David Vancouvering 2008-03-24 20:49:42 UTC
http://hg.netbeans.org/main?cmd=changeset;node=c4a906e53644
Comment 6 Roman Mostyka 2008-03-25 14:18:01 UTC
Verified with build 080325.