Professional Web Applications Themes

Can't connect to MySQL database - Coldfusion Database Access

I've always used Access and am now switching to MySQL. I installed the server which is run locally. I created a new user with full privaleges and a new database. I am able to connect to the database via the OBDC just fine. When I go into the ColdFusion Administrator (CFMX), I try to add the datasource but I get this message: Connection verification failed for data source: TEST []java.sql.SQLException: Communication failure during handshake. Is there a server running on localhost:3306? The root cause was that: java.sql.SQLException: Communication failure during handshake. Is there a server running on localhost:3306? I even ...

  1. #1

    Default Can't connect to MySQL database

    I've always used Access and am now switching to MySQL. I installed the server
    which is run locally. I created a new user with full privaleges and a new
    database. I am able to connect to the database via the OBDC just fine. When I
    go into the ColdFusion Administrator (CFMX), I try to add the datasource but I
    get this message:

    Connection verification failed for data source: TEST
    []java.sql.SQLException: Communication failure during handshake. Is there a
    server running on localhost:3306?
    The root cause was that: java.sql.SQLException: Communication failure during
    handshake. Is there a server running on localhost:3306?

    I even tried using 127.0.0.1 for my hostname but no success.

    Thanks for your help!

    Pricyber Guest

  2. #2

    Default Re: Can't connect to MySQL database

    Pricyber wrote:
    > I've always used Access and am now switching to MySQL. I installed the server
    > which is run locally. I created a new user with full privaleges and a new
    > database. I am able to connect to the database via the OBDC just fine. When I
    > go into the ColdFusion Administrator (CFMX), I try to add the datasource but I
    > get this message:
    >
    > Connection verification failed for data source: TEST
    > []java.sql.SQLException: Communication failure during handshake. Is there a
    > server running on localhost:3306?
    > The root cause was that: java.sql.SQLException: Communication failure during
    > handshake. Is there a server running on localhost:3306?
    >
    > I even tried using 127.0.0.1 for my hostname but no success.
    >
    > Thanks for your help!
    >
    This has been covered several times before--do a quick search in this
    forum and you'll find some info. Also there is a technote about this on
    macromedia.com. I'm assuming you're using MySQL 4.1, so if that's true,
    the long and short of it is you either need to download the JDBC driver
    for MySQL because the one that ships with CF doesn't work with MySQL
    4.1, or you need to get into MySQL and rehash your passwords using the
    old_password() function.

    If you poke around and still need help, post again and I'll try to help
    out further.

    Matt

    --
    Matt Woodward
    Team Macromedia - ColdFusion
    mpwoodward *TMM* Guest

  3. #3

    Default Re: Can't connect to MySQL database

    I have tried downloading the J connector and extracting it to the lib folder as
    directed. I now get an error that is too long to post here. Has Macromedia
    implemented a fix for this? With the relase of CF MX7 Why not includde the
    proper connectors or drivers? If anyone knows of a patch or fix for this
    problem or a link to explicit instructions on how to get this to work could you
    please help?

    RudyZim Guest

  4. #4

    Default Re: Can't connect to MySQL database

    RudyZim wrote:
    > I have tried downloading the J connector and extracting it to the lib folder as
    > directed. I now get an error that is too long to post here. Has Macromedia
    > implemented a fix for this? With the relase of CF MX7 Why not includde the
    > proper connectors or drivers? If anyone knows of a patch or fix for this
    > problem or a link to explicit instructions on how to get this to work could you
    > please help?
    >
    This isn't a fix that Macromedia needs to implement--this is purely an
    issue of getting the driver set up correctly. As for including the
    drivers, my understanding is that MySQL changed their licensing from
    earlier drivers so that they either can't be included or it costs money
    to include them in a product.

    No patches or fixes are necessary, but there is a technote explaining
    how to get things rolling. Make sure you're also setting up your DSN
    information correctly.

    Here's a couple of technotes (the second one is probably more pertinent):
    [url]http://www.macromedia.com/cfusion/knowledgebase/index.cfm?id=tn_19170[/url]
    [url]http://www.macromedia.com/cfusion/knowledgebase/index.cfm?id=6ef0253[/url]

    Hope that helps,
    Matt

    --
    Matt Woodward
    Team Macromedia - ColdFusion
    mpwoodward *TMM* Guest

  5. #5

    Default Re: Can't connect to MySQL database

    Matt,

    I'm having the same probem setting up the data source.

    I've been to:


    [url]http://www.macromedia.com/cfusion/knowledgebase/index.cfm?id=6ef0253[/url]

    But having problems with:

    "Enter the JDBC URL:
    jdbc:mysql://[host]:[port]/[database]"

    Is this address where I placed the jar file?

    I used this address: jdbc:mysql://localhost:8101/cfusion/WEB-INF/lib

    But it won't work.

    Also:

    "Complete username/password, and adjust other data source settings, if
    needed."

    Do I need a username and password? If so, When and where was this defined?

    Thanks for your help

    Scott


    pogothedog1000 Guest

Similar Threads

  1. Replies: 1
    Last Post: January 23rd, 12:06 PM
  2. Replies: 0
    Last Post: January 29th, 02:03 PM
  3. mysql database connect
    By mukraker in forum Macromedia Flex General Discussion
    Replies: 2
    Last Post: April 11th, 03:32 PM
  4. Mac user can't connect to mySQL database
    By benkayuk in forum Macromedia ColdFusion
    Replies: 5
    Last Post: March 4th, 03:25 PM
  5. IS it possible to connect to a MySQL database in asp?
    By Wayne... in forum ASP Database
    Replies: 3
    Last Post: May 10th, 07:10 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139