Jump to content

dbConnect doesn't work


MIKI785

Recommended Posts

Posted

Hello,

I have a problem with dbConnect, it says: "dbConnect failed; Could not connect", why ?

Everything is ok, user, password DB name.. everything. It works with other programs.

handle = dbConnect( "mysql", "dbname=oh1588;host=92.240.***.**", MYSQL_USERNAME, MYSQL_PASSWORD ) 

I tried IP and DNS name, both doesn't work.

Btw. those stars are not in the code.

MYSQL_USERNAME and MYSQL_PASSWORD are defined strings, which are correct credentials.

Lua Scripter

?ucet=miki_cz

Owner of mshost.cz MTA portal.

Posted

Are you sure MySQL server is accepting external connections?

"[...] If you don’t love it, if you’re not having fun doing it, you don’t really love it, you’re going to give up." - Steve Jobs, 2007

Posted
Doesn't work... still the same problem.

Here's an example of connecting to their mysql,

here's your connection type:

dbConnect( "mysql", "dbname=1347157507;host=free-mysql.BizHostNet.com;port=3306", "1347157507", "*****") 

My in-game name: Jaysds1

Retired CMG Scripter

World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode

Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/

 

sE5Qm.png

TiV3C.png

img.php?id=0&text=Lua%20Scripter

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...