Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
 Post subject: MySQL Error (0) Help
PostPosted: Sun Oct 24, 2010 6:33 pm 
Offline
Junior Member

Joined: Mon Apr 26, 2010 12:20 am
Posts: 22
Website: http://www.halloforigin.com
Okay, so I have this imageboard software called "Kusaba X", but I'm having a few problems with it. I had to redeploy my server image a few months back, and I recently re-uploaded all the SQL files and directories. Well, while testing it out, everything worked except the ability to post images. It returns the error "Could not copy uploaded image." I put on debug mode and attempted to reload the HTML files, and it gave me this error:

Code:
(mysqli): SELECT COUNT(DISTINCT `ipmd5`) FROM `kusabaposts` WHERE `boardid` = 1 AND `IS_DELETED` = 0
Error (0):


And a lot of other things that start with (mysqli) and end with Error(0). I've tried replacing the mysqli with mysql, but the same error occurred. Any help on this?

I've made sure that my MySQL database and user were correct and all privileges were granted to the user on the database, btw.


Top
   
 Post subject: Re: MySQL Error (0) Help
PostPosted: Mon Oct 25, 2010 9:48 pm 
Offline
Senior Member

Joined: Sun Oct 30, 2005 7:52 pm
Posts: 97
Zowayixx wrote:
lot of other things that start with (mysqli) and end with Error(0)

Is MySQL running?

Zowayixx wrote:
re-uploaded all the SQL files and directories.

If you upload just the SQL files, then you need to be sure your using the same version of MySQL. Ideally you should be exporting/importing your databases.

--
Travis


Top
   
 Post subject:
PostPosted: Mon Oct 25, 2010 11:53 pm 
Offline
Junior Member

Joined: Mon Apr 26, 2010 12:20 am
Posts: 22
Website: http://www.halloforigin.com
Yes, MySQL is indeed running. I believe I am using the same version of MySQL I was whenever they were working, as I don't really touch the MySQL side of the server, update-wise. Also, I made a database and uploaded the SQL file via the "source *.sql" command, as the sql file itself was too large to be imported manually.


Top
   
 Post subject: Re: MySQL Error (0) Help
PostPosted: Tue Oct 26, 2010 12:30 pm 
Offline
Senior Member

Joined: Sun Oct 30, 2005 7:52 pm
Posts: 97
Zowayixx wrote:
Yes, MySQL is indeed running. I believe I am using the same version of MySQL I was whenever they were working, as I don't really touch the MySQL side of the server, update-wise. Also, I made a database and uploaded the SQL file via the "source *.sql" command, as the sql file itself was too large to be imported manually.

If you imported the .sql file you dumped from the other database, then it shouldn't make a difference on the version of SQL you are running. Hopefully someone else can give you some pointers.

--
Travis


Top
   
 Post subject:
PostPosted: Mon Nov 15, 2010 10:35 pm 
Offline
Junior Member

Joined: Mon Apr 26, 2010 12:20 am
Posts: 22
Website: http://www.halloforigin.com
Anyone have an answer to this? I still haven't figured it out. =/


Top
   
 Post subject:
PostPosted: Tue Nov 16, 2010 8:02 am 
Offline
Senior Member
User avatar

Joined: Sat Aug 30, 2008 1:55 pm
Posts: 1739
Location: Rochester, New York
Without knowing what "Error (0):" means, it's going to be all guesswork. All I can recommend is starting the mysql command line client with the same username/password/hostname/database settings as your application, then try a few queries to make sure they work. If there's a way to get support for your application, they can probably troubleshoot more precisely.

_________________
Code:
/* TODO: need to add signature to posts */


Top
   
 Post subject:
PostPosted: Tue Nov 16, 2010 11:31 pm 
Offline
Junior Member

Joined: Tue Jul 13, 2010 8:28 pm
Posts: 28
You're probably better off asking the people who write the software. If you're well versed in php, I'd suggest digging into the source and changing their error reporting.

I have a feeling Error(0) is specific to whatever app you have. I *don't* think it's being returned from the actual mysqli call. Error catching using mysqli either returns (depending which function you use) an error code or a string containing the error message. Now obviously it's not returning the results of mysqli->error (which should return a message). It's also not the mysqli->errno function, since that returns 0 if there is *NO* error.

I suspect the app is doing some other check/validation and that section of the code outputs the last sql query with an uninformative error code.


Top
   
 Post subject:
PostPosted: Wed Nov 17, 2010 4:41 am 
Offline
Senior Member
User avatar

Joined: Tue Aug 17, 2004 11:37 pm
Posts: 262
Website: http://www.our-lan.com
WLM: nf@our-lan.com
Location: Brisbane, Australia
what happens if you try running the sql statement given manually via phpmyadmin or another cli tool?

_________________
ServerAdmin - www.our-lan.com
"Diplomacy is the art of saying nice doggy whilst looking for a really big stick"
"In my experiece, any attempt to make any system idiot proof will only challenge God to make a better idiot"


Top
   
 Post subject:
PostPosted: Wed Nov 17, 2010 7:33 pm 
Offline
Junior Member

Joined: Mon Apr 26, 2010 12:20 am
Posts: 22
Website: http://www.halloforigin.com
EDIT: Nevermind guys, I fixed it. It was due to a problem on my end. I did chown on a specific directory, but chown'ing the entire directory fixed it. Thanks for the help though. :D


Top
   
PostPosted: Wed Nov 17, 2010 7:43 pm 
Offline
Junior Member
User avatar

Joined: Thu Apr 23, 2009 2:32 am
Posts: 41
Website: http://www.linode.com/
It's generally considered bad form to continuously post in bold text or all caps. Some people may be put off by this, and may not offer assistance with the problem at hand.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group