Bug #20278 User name truncated by one character when connecting via Excel 2003
Submitted: 6 Jun 2006 3:45 Modified: 6 Jun 2006 13:28
Reporter: Jason Gil Email Updates:
Status: Duplicate Impact on me:
None 
Category:Connector / ODBC Severity:S2 (Serious)
Version:3.51.12 OS:Windows (WindowsXP)
Assigned to: CPU Architecture:Any

[6 Jun 2006 3:45] Jason Gil
Description:
Hi,

I've stumbled across what appears to be a bug when using MyODBC 3.51.12 in conjunction with Excel 2003. Seems as if the problem is MyODBC-related, as I'm able to connect to other ODBC data sources using this Excel version. The problem arises when attempting to import data from the database by way of the MyODBC connection. Upon attempting to execute the import, I'm greeted with the MyODBC connector configuration interface. Upon examining the interface, the username is always truncated by one character. For example, if the username has been previously configured as jason, it now shows jaso. If it's Monty, it shows as Mont. Even though I add the character back, and press OK, I'm greeted with the message [MySQL][ODBC 3.51 Driver]User cancelled.

How to repeat:
1. Install MyODBC 3.51.12 on WindowsXP.
2. Configure the DSN by going to Start - Settings - Control Panel - Administrative Tools - Data Sources (ODBC)
3. Open a new Excel 2003 file and navigate to Data - Import External Data - Import Data
4. Click +Connect to New Data Source, then ODBC DSN, then choose the previously created data source. Press Next, and then Finish.
5. You'll be greeted with the MyODBC connector configuration interface, note the username has been truncated.

Suggested fix:
I've fooled with this for some time this evening, to no avail. At present I have no suggested fix, but will keep researching.
[6 Jun 2006 9:21] Tonci Grgin
Hi Jason. Thanks for your problem report.
I was unable to repeat the problem you reported:
  MySQL server 5.0.23 on Suse Linux
  MyODBC 3.51.12, MS Excell 2003 on WinXP SP2
  Login / password: root / 
If your environment is too different from mine, please provide more info.
[6 Jun 2006 12:39] Jason Gil
Hi Tonci,

The only difference between our environments is I'm also running MySQL on the same Windows XP SP2 machine, and that I'm running MySQL 5.0.21. I've just upgraded to 5.0.22. Again though, the DSN connection went just fine, I connected successfully, however when attempting to connect through Excel 2003 the MySQL Connector/ODBC Configuration window popped up, and the User name was truncated by one character. As a test I also created a new DSN, this time using the shorter username: "wjg" but sure enough, when attempting to connect through Excel, it popped up as just "wj".

Out of curiosity, I created a second user named "wj" and granted him the same privileges as "wjg". Sure enough, although the name was ultimately truncated by Excel, the connection worked, despite there being no actual DSN connection using this name.

Also made sure Excel was completely up-to-date, sure enough it is.
[6 Jun 2006 13:28] Tonci Grgin
Hi Jason. 
This is a duplicate of bug 16653. Please do not submit same report twice. I will post my findings there.