ColdFusion comes with the ability to connect via ODBC to a MySQL database.
NOTE: MySQL databases need to be in ALL CAPS in order for them to work properly with ColdFusion. |
This allows you to create a dynamic link between your Web site and MySQL. How is that done? Follow the instructions below.
-
Open your Web browser and connect to:
http://YOUR-DOMAIN.NAME/cfide/administrator
-
Enter your password in the Password text box.
-
The ColdFusion Administrator page will be launched.
-
On the left menu bar, under data sources, click ODBC. The ODBC Data Sources Available to ColdFusion page will be displayed.
-
To add a mySQL database, enter the data source name in the Data Source Name text box. The data source name can be any of your choice.
-
In the ODBC Drivers drop down box choose, myODBC mySQL Driver.
-
Click the Add button to add the ODBC driver.
-
The Create ODBC Data Source [myODBC mySQL Driver] page will appear. This is where you will configure the settings to connect to your database.
-
The Data Source Name text box should already be filled out with the name you gave earlier.
-
The Description text box is where you can give a brief description of the database connection.
-
The Database Name text box is for the name of the database you are connecting to (remember the database name must use all upper-case letters).
-
The Server Host Name text box is where you will need to provide the name of the server that your database is on. If your database is on the same server, use the default Local Host.
-
The Server Porttext box should remain 3306. If your database is on a different server and you know the port number, make the necessary changes to use the correct port.
-
Click the CF Settings button.
-
A new screen will appear with some additional information.
-
The Username and Password text boxes are where you enter the Username and Password for your mySQL database.
-
Click the Create button to add the connection.
-
The ODBC Data Sources Available to ColdFusion screen will appear. On the right side of the screen it should say Verified next to the data source you just added.
Please note: the information on this page applies to ITS web hosting plans. It may or may not apply to other environments. If you are looking for a feature described here, or better support from your hosting provider, please consider hosting your site with ITS!
Copyright © 1996-2024, Integrated Technical Solutions, Inc., all rights reserved. See Terms/Legal for trademarks, copyright, and terms of use.
Naperville, IL 60563
fax 630.420.2771