This video illustrates following:
1- How to find SQL Server Port number using SQL Server Management Studio (SSMS)
2- How to find Default and named instances of SQL Server Port using Regedit
3- How to read values from registry related to SQL Server
4- How to find SQL Server Port Number using T-SQL Script
Script to get Port Number for SQL Server Instance
1- How to find SQL Server Port number using SQL Server Management Studio (SSMS)
2- How to find Default and named instances of SQL Server Port using Regedit
3- How to read values from registry related to SQL Server
4- How to find SQL Server Port Number using T-SQL Script
Script to get Port Number for SQL Server Instance
DECLARE @PortNumber VARCHAR(10), @KeyValue VARCHAR(100) IF CHARINDEX('\',@@SERVERNAME,0) <>0 BEGIN SET @KeyValue = 'SOFTWARE\MICROSOFT\Microsoft SQL Server\'+@@SERVICENAME+'\MSSQLServer\Supersocketnetlib\TCP' END ELSE BEGIN SET @keyValue = 'SOFTWARE\MICROSOFT\MSSQLServer\MSSQLServer \Supersocketnetlib\TCP' END --How to read Registry in T-SQL Terms - ROOTKEY, KEY, VALUENAME,VALUE EXEC master..xp_regread 'HKEY_LOCAL_MACHINE',@KeyValue,'Tcpport',@value=@PortNumber OUTPUT SELECT 'SQLSERVER_NAME: '+@@SERVERNAME + ' : SQL SERVER Port Number:'+CONVERT(VARCHAR(10),
@PortNumber)
Get SQL Server Port Number using SQL Server Management Studio - SQL Server DBA Tutorial
Your blog is in a convincing manner, thanks for sharing such an information with lots of your effort and time
ReplyDeletesql dba training
sql server dba online training
Could you please help me on this topic
ReplyDeletehttps://stackoverflow.com/questions/68462343/i-cant-access-mssql-server-remotely
I'll PAY you if you could help me.
kindly reply to Quhtani@gmail.com