Alain Cruz
Alain Cruz

Reputation: 5097

How to create a windows authentication user on SQL Server 2014?

I would like to connect to the company's SQL Server 2014, where I am working at, with my computer using windows authentication. I need this to deploy from my machine SSIS packages, without having to access remotely our server's machine.

I have been trying to add a login with my computer name plus my user as MY_COMPUTER\USER, but I keep getting an error, which tells me the it wasn't able to find the domain of my computer.

So, how can I connect my computer to our SQL Server using a windows authentication?

Upvotes: 0

Views: 1837

Answers (2)

Alain Cruz
Alain Cruz

Reputation: 5097

We have a windows network domain joined with our SQL Server. I had already created a user for my computer on our windows network, but I wasn't logging in using the new user.

Upvotes: 0

Matt
Matt

Reputation: 14361

CREATE LOGIN [DomainName\Username] FROM WINDOWS WITH DEFAULT_DATABASE=[master], DEFAULT_LANGUAGE=[us_english]

Your local computer name isn't part of this at all. DomainName is the name of the windows network domain name that your SQL server would be joined to in this case. If your SQL server is not joined to a domain then that is a different scenario and I can't test but I would think you would use the computer name of the SQL Server in place of domain name and then the name of the local user....

Anyway, do you know your Domain Name?

DomainName\Username

If not joined to a domain try

SqlServerComputername\Username

Upvotes: 1

Related Questions