How SQL server connects to remote MySQL

Source: Internet
Author: User

How SQL server connects to remote MySQL

 

Recently encountered"SQLHow to connect remotelyMySQL"Now the problem is finally solved, so I will post the method:(What I useOperating SystemYesWin7, Database isSql2005.)1InSQL ServerServerInstall OnMySQL ODBCDriver;

2After installation,In the management tool-ODBCData Source-SystemDSN-Add-SelectMySQL ODBC 3.51 driver-Complete

 

MySQL connection parameters are displayed.

Data Source Name: Data Source Name

Decription: description.

Server: MySQLServerIP

Port: MySQL port. The default value is 3306. You can change the value.

User: connection account (the account authorized on MySQL and corresponding permissions)

Password: Password

Database: select the connected database

After filling out the information, click test. The prompt box will pop out.

After successful:

 

3,Open the SQL database, find the link server, and create the link server. Everyone will, so I will send the parameter. Other common options will not be filled in. OK.

Note: select "Microsoft ole db provider for ODBC drivers" for the access interface ".

Data source: select the created ODBC interface.

 

4Test:

(Query statement)

Select* From openquery (MySQL,'Select * From table ')

(Insert Statement)

Insert openquery (MySQL,'Select * From table') (ID, name, password) values (8 ,'Zidane ', '123 ')

 

I used SQL Server 2008. The experiment was successful. Some fields may need type conversion.

From:Http://www.dwway.com/article-8181-1.html

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.