LogonUser
and LogonAuth
specify a valid user name and password? If you're sure the username and password are correct, call SQLError
, SQLGetDiagRec
, or SQLGetDiagField(SQL_DIAG_NATIVE)
. The native error is the error code returned by GetLastError
and shows why the Easysoft ODBC-ODBC Bridge server failed to log on. Later versions of the ODBC-ODBC Bridge return a second diagnostic "authentication error number nnnn" (where nnnn is the error number), removing the need for GetLastError
.
This table lists some common errors and their solutions.
Error code | Description |
---|---|
1385 |
Logon Failure: the user has not been granted the requested logon type at this computer. Check the user has the Logon Locally permission.
Standard users can't log onto a domain controller. If the ODBC-ODBC Bridge server is running on your primary or secondary domain controller on Microsoft Windows 2003 Server, your options are:
|
1314 | A required privilege is not held by the client. The ODBC-ODBC Bridge server needs the Act as part of the operating system access right to authenticate and become the LogonUser . |
1326 | Logon Failure: unknown username or bad password. The user name is not a valid user or the password is invalid. If you've checked these credentials are valid and the user is in a Windows domain, try prefixing the user name with a domain. For example, MYDOMAIN/User_name. |
1327 |
Error_Account_Restriction: Indicates a referenced user name and authentication information are valid, but some user account restriction has prevented successful authentication (such as time-of-day restrictions).
On Windows XP, this can occur if you specify an empty password. By default, users with no passwords are only allowed to log in at the console. |
1328 | Account logon time restriction violation. |
1330 | The specified account password has expired. |
1331 | Logon failure: account currently disabled. Re-enable the account. |
1355 | The specified domain did not exist. You are using the Domain/User_name syntax in LogonUser and Domain does not exist. |
1909 | Account locked out. Unlock the account. |
87 | Parameter incorrect. You have specified an invalid username for the LogonUser attribute. For example, a zero length one. Check the LogonUser attribute is spelt correctly in your ODBC data source. |
1907 | The user must change the password before logging on for the first time. Check the logon settings for the user you are using or log on as that user and set the password. |
1792 | An attempt was made to log on, but the network logon service was not started. In Windows Services and make sure the Net Logon service is running. |