0

Debian 7 x64, MSSQL 2008

Installed:

  • PHP 5.4.36-0
  • FreeTSD 0.91
  • unixodbc

If I connect with:

tsql -S server_name -U user_name -P password -D db_name

all is ok, but if I try to connect via php:

mssql_connect('server_name', 'user_name', 'password')

it always says

Login failed for user 'user_name'. (severity 14)

Can anyone help me with this? Thanks.

update: Found a solution: make the password shorter and everything was fine. Old password contains 32 characters.

0

1 Answer 1

1

Did you check this?

"To increase security, the error message that is returned to the client deliberately hides the nature of the authentication error. However, in the SQL Server error log, a corresponding error contains an error state that maps to an authentication failure condition. Compare the error state to the following list to determine the reason for the login failure."

Sign up to request clarification or add additional context in comments.

3 Comments

Login failed for user 'user_name'. Reason: Password did not match that for the login provided.
Found a solution: make the password shorter and everything was fine. Old password contains 32 characters.
well, glad to help (:

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.