I am trying to create a database and getting a 262 error.

Krista Bland 0 Reputation points
2026-08-26T17:18:59.79+00:00

I am on the admin account of my personal computer, and my instructor in the course I'm taking told me to right click the SSMS 22 icon and run it as an admin, so I did that first, and I'm still getting the same error. It seems to me that I don't have admin access on SSMS itself, and I think I should - what am I doing wrong?

Gemini advised that I check if I have sysadmin access, so I typed select is_srvrolemember ('sysadmin') into my query window, and got a 0.

How do I give myself admin access and why don't I automatically have it, since I own this computer?

SQL Server | Other
SQL Server | Other

Additional SQL Server features and topics not covered by specific categories

0 comments No comments

Answer accepted by question author
Deepesh Dhake 840 Reputation points
2026-08-26T17:56:54.2233333+00:00

Which account were you signed in as when you installed SQL Server? That one most likely already has sysadmin.

Log in with it and run:

ALTER SERVER ROLE sysadmin ADD MEMBER [COMPUTERNAME\YourUser];
(Get your name with SELECT SUSER_NAME();.)

If no account has sysadmin, use single-user mode: stop the SQL Server service, restart it with -m, connect via sqlcmd as your Windows admin, run the same command, then remove -m and restart. Microsoft documents this fully.

Error 262 is a SQL Server permission

Was this answer helpful?

1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.