Frequently Asked Questions

Help Center Search

Setting up a Data Source in ColdFusion

Print this Article
Comment on this Article
Last Updated: December 11, 2007 1:59 PM

NOTE: You may have to modify your /etc/hosts file in order for ColdFusion datasources to work with Plesk. This is because Plesk database user permissions apply only to localhost and your primary IP address. ColdFusion uses your primary full hostname to connect, and this must be linked to your primary IP address through your /etc/hosts file for a successful connection to occur.

If your file resembles the following:

127.0.0.1 [full_hostname] [short_hostname] localhost localhost.localdomain

it should be modified with your preferred text editor as shown below, substituting your server's values for those in brackets:

127.0.0.1 localhost localhost.localdomain
[your_primary_ip] [full_hostname] [short_hostname]

To Set Up a Data Source In ColdFusion

  1. Log in to the administrator page at http://[machinename]/CFIDE/administrator/index.cfm.
  2. From Data & Services, select Data Sources.
  3. In the Data Source Name box, specify a name, such as mysql_local.
  4. Select the driver type, MySQL, and then click Add.
  5. In the Database, Username, and Password fields, specify the information from the MySQL database you created earlier.
  6. To add a description, in the Description field, specify the description.
  7. Click Submit.

You can use the MySQL data source inside your ColdFusion applications. You may want to use a program such as Macromedia Dreamweaver to receive the full benefits of ColdFusion.