Use Excel to analyze MySQL Data (1)

Source: Internet
Author: User
Tags mysql odbc driver
Even though we have powerful reporting tools like Microsoft Crystal Reports and some other flexible customer management application tools in the current era, many enterprises analyze such sales statistics and revenue information, microsoft Excel is still the most commonly used tool. Of course, this is not without reason: Excel has become an indispensable part of the office environment with its rich and powerful functions.

Even though we have powerful reporting tools like Microsoft Crystal Reports and some other flexible customer management application tools in the current era, many enterprises analyze such sales statistics and revenue information, microsoft Excel is still the most commonly used tool. Of course, this is not without reason: Excel has become an indispensable part of the office environment with its rich and powerful functions.

Even though we have powerful reporting tools like Microsoft Crystal Reports and some other flexible customer management application tools in the current era, many enterprises analyze such sales statistics and revenue information, microsoft Excel is still the most commonly used tool. Of course, this is not without reason: Excel has become an indispensable tool in the office environment with its rich and powerful functions.
However, the company is gradually storing data in remote databases, so that employees can read and modify data from different places. However, the previous work flow habits are hard to break. What should you do when your boss needs to use Excel at the far end to view recent sales data in a pie chart?
Maybe you didn't think that you could connect Excel to a database, and not only limited to Microsoft's SQL Server. In fact, Excel can be connected to all mainstream databases, such as MySQL, PostgreSQL, and Oracle, as long as the database provides an ODBC driver. In this article, we will take MySQL as an example to learn how to connect Excel to MySQL.
Install MyODBC

ODBC provides a standard way to execute almost all common tasks, such as data recovery, deletion, and selection, which means that for different databases, you need to write different drivers to interpret your commands as standard ODBC standards. MySQL has long been available with a specific ODBC driver, known as MyODBC. Install the MyODBC driver on every computer that you want to connect to MySQL using Excel.
Now, first download the MyODBC Installer (http://dev.mysql.com/downloads/connector/odbc ). The installation package is only 2.3 M. If you are using a broadband connection, the download should be completed soon.
After you download MyODBC, click the icon to start installation. If you do not have special installation requirements, select a typical installation. Click the Install button to start the installation. After the installation is complete, click the complete button to launch the installation program.

Configure MyODBC 
If your operating system is Windows XP, you can open the ODBC terminal as follows: Start Menu: configure the ODBC Data Source (ODBC), which is the Development Control Panel's development management tool ).

498) this. width = 498; 'onmousewheel = 'javascript: return big (this) 'height = 368 alt = "" src = "/files/uploadimg/20070305/1017390 .jpg" width = 450>

ODBC data source Manager

Click "Add (Add)" to Add a new data source and scroll the slider until you find the MySQL ODBC driver. Double-click this item to start the configuration process. Shows the Configuration window.

498) this. width = 498; 'onmousewheel = 'javascript: return big (this) 'height = 382 alt = "" src = "/files/uploadimg/20070305/1017391 .jpg" width = 450>

Add MySQL DATA SOURCES

After filling in the options, click the "Test" button to confirm whether the driver can be connected to MySQL. If your database server and Excel are on the same machine, using "localhost" or "127.0.0.1" as the server address may not take effect. Then, you can use a node as the server address, so that the driver uses a named channel instead of TCP/IP to connect to the database. If you want to connect to a remote database, do not forget to make sure that the firewall blocks the port connecting you to MySQL (usually 3306 ). Finally, do not forget to use an existing valid logon account. If you need to not only read data, but also insert and update data, you must note that the Logon account must have the relevant permissions.
Once the connection test is successful, click "OK" to add one more data source in the existing data source list. Next, we will connect Excel to MySQL.

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.