mysql host name
Posted: Mon Sep 22, 2008 9:32 am
Hi there,
I would need some expert help, I really appreciate your time that you have taken to read my post.
Questions:
1. I am in a need to use username/password from a sql server, and MySQL for the rest of the site conent. So, basically I need to be able to connect to two databases (sometimes on the same page), one to retrieve username and maintain sessions, another to extract site content. Is that possible? I was thinking of having two include files - one for mssql one for mysql.
2. I have php on one machine, mysql on another and sql server on the 3rd machine. I can connect to the sql server but can't connect to mysql. I have tested it locally and mysql works fine with php. It's not recognising the host name while trying to connect remotely. I put the external IP/server name, none seemed to work. It only recognises localhost when tested locally. I have read somewhere mysql uses localhost as default host name. Does it mean I have to change mysql host name somewhere in my php.ini or in mysql configuration file? Or is there something I am missing. Please advise.
Many Thanks,
I would need some expert help, I really appreciate your time that you have taken to read my post.
Questions:
1. I am in a need to use username/password from a sql server, and MySQL for the rest of the site conent. So, basically I need to be able to connect to two databases (sometimes on the same page), one to retrieve username and maintain sessions, another to extract site content. Is that possible? I was thinking of having two include files - one for mssql one for mysql.
2. I have php on one machine, mysql on another and sql server on the 3rd machine. I can connect to the sql server but can't connect to mysql. I have tested it locally and mysql works fine with php. It's not recognising the host name while trying to connect remotely. I put the external IP/server name, none seemed to work. It only recognises localhost when tested locally. I have read somewhere mysql uses localhost as default host name. Does it mean I have to change mysql host name somewhere in my php.ini or in mysql configuration file? Or is there something I am missing. Please advise.
Many Thanks,