Using the MySQL database in. Net

Source: Internet
Author: User
Tags mysql database visual studio

Using SQL Server in. NET is always a thing. A few days ago to learn through JDBC using Java connection MySQL database, I think. NET can also use the MySQL database? The answer is yes, the method is also very simple, where I use C # as a programming language, the way I have sorted out to share with you.

Want to be in. NET to use the MySQL database, the steps are:

1. Download MySQL driver package

2. Reference the MySQL class component that has been compiled in the driver package

3. Write code

Step one: Download the MySQL driver package

When I wrote an article, the latest driver package was 5.2 and supported Visual Studio 2008. The official download address is http://dev.mysql.com/downloads/connector/net/5.2.html.

Step Two:

The downloaded file is a compressed file that is decompressed to the local disk. Locate the MySql.Data.dll file in the Bin folder, which is the component we want to refer to. Refer it to your project through Visual Studio

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.