Jump to content

Problem with MySQL


Neproify

Recommended Posts

Posted

Hello, I have the code like this:

  
local SQL 
  
local function connect() 
    -- w ponizszej linii uzupelnij dane autoryzacji 
    SQL = dbConnect("mysql", "dbname=game;host=localhost", "root", "password", "share=1") 
    if (not SQL) then 
        outputServerLog("BRAK POLACZENIA Z BAZA DANYCH!") 
    else 
        zapytanie("SET NAMES utf8;") 
    end 
  
end 
  

And when I start the server the server log show this error:

[2014-02-02 17:07:31] ERROR: [XyzzyRP]/DB2/sql.lua:16: dbConnect failed; Can't connect to local MySQL server through socket '' (111) 

Are there any solution of this problem?

Posted

Have u successfully tested your local mysql database if it's well configured ? "share=0" for mysql databases anyways. Hope you have created "game" database on your server. U can also try : host=127.0.0.1 .

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...