Methods for using Linkserver to connect Oracle in SQL Server _mssql

Source: Internet
Author: User
Tags string format management studio sql server management sql server management studio

1. Install Oracle Client

The prerequisite for connecting to Oracle is to install Oracle Client on the SQL Server server. Oracle client download addresses are as follows:

Http://www.oracle.com/technetwork/cn/database/enterprise-edition/downloads/index.html

After installation to modify the corresponding TNSNames file to connect the corresponding data, the file directory:

Oracle Installation Path \product\10.2.0\client_1\network\admin

Connection string Format:

QAS =
(DESCRIPTION =
(Address_list =
(address = (PROTOCOL = TCP) (HOST = 10.10.10.181) (PORT = 1527))
)
(Connect_data =
(service_name = QAS)
)
)

2. Establish Link Server connection

First open SQL Server Management Studio, expand to Server Objects-->linked server, and right-click to select new linked server to enter information for link server.

When the input is complete, the information appears as follows:

3. Using Link Server

SQL Server provides two ways to connect to link Server:

SELECT * FROM OPENQUERY (QAS, ' select * from Sapr3.mseg ')
Select Top * from [QAS]. [SAPR3]. [Mseg]

Attention:

1 The second way to take note of the case
2 The index is not used in either way, and the use of mass data is not supported

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.