Hi faizanak,
Refer below SQL query
--Object: LinkedServer [DEV3] Script Date: 11/21/2022 8:59:38 AM
EXEC master.dbo.sp_addlinkedserver @server = N'DEV3', @srvproduct=N'Oracle', @provider=N'OraOLEDB.Oracle', @datasrc=N'(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.112)(PORT = 1521))
)
(CONNECT_DATA =
(SID =DEV)
)
)'
--For security reasons the linked server remote logins password is changed with ########
EXEC master.dbo.sp_addlinkedsrvlogin @rmtsrvname=N'DEV3',@useself=N'False',@locallogin=NULL,@rmtuser=N'system',@rmtpassword='oracle'
GO