Collections:
Verifying a User Name with SQLCMD Tool in SQL Server
How To Verify a User name with SQLCMD Tool in SQL Server?
✍: FYIcenter.com
The quickest way to verify a user name in a database is probably to use the SQLCMD tool. You can connect to the server, select the database, and check which user name is linked the current login name as shown below.
Start a command window and enter the following command:
C:\>SQLCMD -S LOCALHOST\SQLEXPRESS -U Fyi_Login -P IYF 1> USE FyiCenterData; 2> GO Changed database context to 'FyiCenterData'. 1> PRINT User_Name(); 2> GO Fyi_User
This shows user "Fyi_User" in database "FyiCenterData" is linked to login name "Fyi_Login".
⇒ "ALTER USER" - Changing the Name of a Database User in SQL Server
⇐ Finding the Login Name Linked to a Given User Name in SQL Server
2017-08-25, 6475🔥, 0💬
Popular Posts:
How To Query Tables and Loop through the Returning Rows in MySQL? The best way to query tables and l...
What Is Transport Network Substrate (TNS) in Oracle? TNS, Transport Network Substrate, is a foundati...
How To Convert Binary Strings into Hexadecimal Character Strings in SQL Server? When a query returns...
How To Locate and Take Substrings with CHARINDEX() and SUBSTRING() Functions in SQL Server Transact-...
How To Change the Password for Your Own User Account in MySQL? If you want to change the password of...