News:

LVCS.NET offers low cost domain registration services.

Main Menu

mysql_connect

Started by whiteknight, February 17, 2007, 02:16:09 AM

Previous topic - Next topic

whiteknight

First, I would like to say that I know this isn't exactly the right place for this posting.  I have an account with Freepgs and purchased additional hosting from LVCS.  So far it has been a little problomatic getting things up there.  One of the errors I'm getting is this:

Warning: mysql_connect(): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) in /home/content/b/u/m/bumpsarcade/html/arcade/config.php on line 11
Could not connect: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

I have an arcade that I host through Freepgs.  I'm also trying to get this up at LVCS.  When I go to dump data into MySQL I get this:

Error

SQL query:

CREATE TABLE `ava_settings` (
`site_name` text NOT NULL ,
`site_url` text NOT NULL ,
`template_url` text NOT NULL ,
`max_results` text NOT NULL ,
`image_height` text NOT NULL ,
`image_width` text NOT NULL ,
`adsense` char( 1 ) NOT NULL default '',
`cat_numbers` char( 1 ) NOT NULL default '',
`seo_on` char( 1 ) NOT NULL default '',
`email_on` char( 2 ) NOT NULL default ''
) ENGINE = MYISAM DEFAULT CHARSET = latin1;

MySQL said: Documentation
#1064 - You have an error in your SQL syntax.  Check the manual that corresponds to your MySQL server version for the right syntax to use near 'DEFAULT CHARSET=latin1' at line 12


This is the very same one I'm using at freepgs without any problems.  I looked the syntax up and it appears to be correct.  Somebody please help.

brainiac744

You could -try- removing this bit from the end:

DEFAULT CHARSET = latin1

That might make things a bit odd with the table though, you can always dump the table if it screws it up though.

whiteknight

Thanks, removing the DEFAULT CHARSET seems to have worked.  I'm still facing the other problem:


Warning: mysql_connect(): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) in /home/content/b/u/m/bumpsarcade/html/arcade/config.php on line 11
Could not connect: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

All the connection info contained in config.php is correct.  Any idea what might be causing this?  You have been very helpful and I appreciate the effort you have given so far.

brainiac744

That appears to be a server problem. I know I get that error on my local server when mysql isn't started up, not sure what else might cause it though. Try opening a trouble ticket (or whatever it's called on lvcs)

whiteknight

I got in touch with their technical support who basically said that this is a script error.  I doubt that this:

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/content/b/u/m/bumpsarcade/html/arcade/login.php on line 33
You could not be logged in! Please make sure you enter the correct password and your account is active.
Username    

is a script error.  It's running on this server just fine for starters.  If this is a script error, any idea how to correct it?

brainiac744

OK, Are you sure you're using the right database name / username / password? Double check the database information page to be sure that you are.