I don’t know much (really anything) about SQL Server 2008, but I just need to make a few basic queries.
My question is:
While using Windows Authentication (on SQL Server 2008 R2), what data do I fill in the mssql_connect field?
$userName = "username";
$password = "password";
$serverName = "localhost(??)";
$connection = mssql_connect($serverName, $userName, $password);
What should those variables be or how can I easily change the set-up of my SQL Server or…whatever the quickest way there is to get this connected?
Any help would be great, I haven’t found too much info, let alone clear info on this anywhere.
If you are running on a XAMP environment, then it would stand to reason that you are running everything locally. If that’s the case, your server would be ‘localhost’ or ‘127.0.0.1’ and you can define your own accounts in SQL. As I said, I don’t use windows accounts myself, but you can add an NT account to your “server” and then in SQL Server Mgmt tool set that user to have access to the DB you are using. Then you have set the account and password and know what they are. If you have trouble with the useracount, you can try “computerName\userName”
If you are not the admin, you’ll need to get the relevant information from them.