KB: MySQL DbLib Connection Uses Windows Credentials Instead of Configured MySQL Authentication

Altium Designer Altium Designer
In some cases, Altium Designer DbLib or SVNDbLib connections to MySQL may attempt to authenticate using the current Windows user account instead of the configured MySQL credentials. This can result in failed connection tests, authentication errors after reopening the connection dialog, or MySQL logs showing Windows-based login attempts. The issue typically occurs when MySQL credentials are not being persisted correctly by the ODBC data source. Configuring a properly credentialed 64-bit System DSN ensures the required MySQL credentials are available to the connection and prevents authentication fallback to the Windows user context.

At a Glance

In some cases, Altium Designer DbLib or SVNDbLib connections to MySQL may attempt to authenticate using the current Windows user account instead of the configured MySQL credentials. This can result in failed connection tests, authentication errors after reopening the connection dialog, or MySQL logs showing Windows-based login attempts. The issue typically occurs when MySQL credentials are not being persisted correctly by the ODBC data source. Configuring a properly credentialed 64-bit System DSN ensures the required MySQL credentials are available to the connection and prevents authentication fallback to the Windows user context.
Go Deeper with AI:

Solution Details

Authentication Attempts Use the Wrong Account

One or more of the following symptoms may be observed:

  • Test Connection fails unless the username and password are entered again each time.
  • The connection works temporarily but fails after reopening the dialog.
  • Tables and schema are visible, but authentication fails during normal use.
  • MySQL logs show login attempts using a Windows user and domain instead of a MySQL account.
  • The same .DbLib file and DSN work correctly on one machine but fail on another.
  • Connection testing succeeds only for the current session and does not persist.

Microsoft Data Link Error dialog showing connection test failure: provider initialization failed; MySQL ODBC 8.0 reports “Access denied for user ‘altium’@…de (using password: YES)”

Credentials Are Not Persisted to the Connection

This behavior can occur because of the interaction between Altium Designer, MSDASQL, and the MySQL ODBC driver:

  • Altium Designer does not store database credentials. Values entered in the connection dialog are available only for the current session.
  • DbLib and SVNDbLib connections use an OLE DB connection string and commonly rely on Microsoft's ODBC provider (MSDASQL) when connecting to ODBC data sources.
  • The MySQL ODBC driver stores credentials as part of the DSN configuration.
  • If the DSN does not persist credentials correctly, the OLE DB provider receives no database user information.
  • When no MySQL user is supplied, MSDASQL may fall back to the current Windows user context.
  • MySQL does not support Windows integrated authentication, causing authentication to fail.
  • User DSNs are more susceptible to permission issues, security policies, credential persistence issues, and 32-bit/64-bit mismatches.
  • Being able to browse tables or schema does not necessarily confirm that subsequent authenticated operations will succeed.

Configure a Persistent System DSN

  • Use a properly credentialed 64-bit System DSN for MySQL.
  • Reference the System DSN from the Database Library instead of relying on session-entered credentials.
  • Avoid using User DSNs in enterprise or security-hardened environments.
  • Ensure the ODBC driver, DSN, and Altium Designer installation are all 64-bit components.

Create and Verify the System DSN

  1. Open the 64-bit ODBC Administrator with administrative privileges using C:\Windows\System32\odbcad32.exe.
  2. Confirm that the 64-bit ODBC Administrator is being used and not the 32-bit version.
  3. Select the System DSN tab and choose Add.
  4. Select MySQL ODBC 8.0 Unicode Driver.
  5. Enter the MySQL server name, database name, MySQL username, and MySQL password.
  6. Select Test and save the DSN.
  7. Open the .DbLib or .SVNDbLib file in Altium Designer.
  8. Reference the configured System DSN and test the connection.
  9. Close and reopen the connection dialog, then test again to verify credential persistence.
  10. Verify that the MySQL server log shows the configured MySQL account rather than a Windows account in the format DOMAIN\Username.

Additional Notes

  • Altium Designer requires a compatible 64-bit database access layer.
  • Altium Designer does not retain database credentials by design.
  • Re-entering credentials in Altium Designer enables only a temporary connection test.
  • ODBC credentials are machine-specific and must be configured on every workstation that opens the .DbLib or .SVNDbLib file.
  • Optional: verify System DSN registry entries if additional troubleshooting is required.
  • If the same library works on one machine but not another, compare DSN type, driver version, driver bitness, and credential persistence configuration.

References

If you find an issue, select the text/image and pressCtrl + Enterto send us your feedback.