Forums
This topic is locked
Can't connect to mySQl ...my DB Connection!!!
Posted 22 Oct 2001 03:37:58
1
has voted
22 Oct 2001 03:37:58 Marc Bacchus posted:
I installed phakt..I tried both myOBDC & JBDC connections and both came up with the same error....{{{Something like this...can't connect for usrname.myISP.net...}}}...Is there another way to connect to my mySQL DB?? Can some please help me.Replies
Replied 22 Oct 2001 09:37:19
22 Oct 2001 09:37:19 Michael O'Neill replied:
Hi, the latest update of PHAkt 1.06 has a tutorial included in the docs that covers connection configuration.
I have also seen PHAkt connection information on this forum but I can't remember where!!! do a search maybe?
Hope this helps
Mike.
I have also seen PHAkt connection information on this forum but I can't remember where!!! do a search maybe?
Hope this helps
Mike.
Replied 22 Oct 2001 12:06:10
22 Oct 2001 12:06:10 Bruno Mairlot replied:
This is probably because your ISP doesn't allow you to connect remotely.
Try this simple script :
<pre id=code><font face=courier size=2 id=code>
<?php
$dbh=mysql_connect("localhost",yourLogin,yourPassword);
if(!$dbh){
echo "Connection not successful";
}
else{
echo "Connection successful";
}
?>
</font id=code></pre id=code>
Upload it to your web space, and execute it (Don't forget about the <html>...stuffs)
If the connexion is successful, it probably means that you cannot connect remotely.
At that point you have two solutions :
1. Ask your provider to allow you to remotely connect (Try with an ODBC connexion)
2. Install a local running version of MySQL, and use this to connect in ultradev.
--- Better to die trying, than never try at all ---
Try this simple script :
<pre id=code><font face=courier size=2 id=code>
<?php
$dbh=mysql_connect("localhost",yourLogin,yourPassword);
if(!$dbh){
echo "Connection not successful";
}
else{
echo "Connection successful";
}
?>
</font id=code></pre id=code>
Upload it to your web space, and execute it (Don't forget about the <html>...stuffs)
If the connexion is successful, it probably means that you cannot connect remotely.
At that point you have two solutions :
1. Ask your provider to allow you to remotely connect (Try with an ODBC connexion)
2. Install a local running version of MySQL, and use this to connect in ultradev.
--- Better to die trying, than never try at all ---
Replied 22 Oct 2001 16:56:04
22 Oct 2001 16:56:04 Ryan Schwiebert replied:
I HIGHLY sugest this tutorial:
www.udzone.com/showDetail.asp?TypeId=2&NewsId=1221
It helped me out a lot with making my connections.
www.udzone.com/showDetail.asp?TypeId=2&NewsId=1221
It helped me out a lot with making my connections.
Replied 22 Oct 2001 16:58:28
22 Oct 2001 16:58:28 Bruno Mairlot replied:
But how did manage to get your connection working exactly ?
What was wrong ?
--- Better to die trying, than never try at all ---
What was wrong ?
--- Better to die trying, than never try at all ---
Replied 23 Oct 2001 00:30:41
23 Oct 2001 00:30:41 Marc Bacchus replied:
I already followed the tutorial that 'ryans' suggested...it did help, but the error I keep getting is the same the tutorial shows..(([Possible Problem]
If you get an error message during the test that says something like "server connection denies access to data source" or "[TCX][MyODBC]Host'.IP.routername.DSLcompany.net' is not allowed to connect to the MySQL server", you need to talk to your hosting company.
They need to run the following from the MySQL command line using the root user. (note EXACT syntax, with .* and "%"
mysql> grant all privileges on accname_dbname.* to accname_dbuser@"%" identified by 'passwrd';
> Query OK, 0 rows affected (0.16 sec)
>
> mysql> quit
))<b></b>
I will get a hold of my host and see if this solution helps. Maybe this could be resolved. I get the same error as above "not exactly, but very similiar..it says I don't have permission, then it list my ISP...
...Maehdros...I can connect to mysql with php scripts & my ISP told me that there's nothing on there system that would prevent me from connecting to the server...
If you get an error message during the test that says something like "server connection denies access to data source" or "[TCX][MyODBC]Host'.IP.routername.DSLcompany.net' is not allowed to connect to the MySQL server", you need to talk to your hosting company.
They need to run the following from the MySQL command line using the root user. (note EXACT syntax, with .* and "%"
mysql> grant all privileges on accname_dbname.* to accname_dbuser@"%" identified by 'passwrd';
> Query OK, 0 rows affected (0.16 sec)
>
> mysql> quit
))<b></b>
I will get a hold of my host and see if this solution helps. Maybe this could be resolved. I get the same error as above "not exactly, but very similiar..it says I don't have permission, then it list my ISP...
...Maehdros...I can connect to mysql with php scripts & my ISP told me that there's nothing on there system that would prevent me from connecting to the server...
Replied 23 Oct 2001 10:28:19
23 Oct 2001 10:28:19 Bruno Mairlot replied:
Yes this is indeed a connection refused.
If your ISP refuses to allow you remote connection, then you have only two solutions :
1. Change your ISP (which might be difficult)
2. Run a local version of mysql server. (Download : www.mysql.com/
If you have trouble for installation or setting up, post here.
--- Better to die trying, than never try at all ---
If your ISP refuses to allow you remote connection, then you have only two solutions :
1. Change your ISP (which might be difficult)
2. Run a local version of mysql server. (Download : www.mysql.com/
If you have trouble for installation or setting up, post here.
--- Better to die trying, than never try at all ---