View Full Version : INSERT command denied
springbok
09-18-2008, 08:51 AM
I've got a pretty stable php script I've been working on using a local wamp server, and I've just moved it onto your server. I replaced the msyql connection info, made sure that I'm using the right host, username, password, etc. I'm not having any problem connecting to the database. It just won't let me insert anything, for some reason.
Tyler
09-18-2008, 12:54 PM
Copy and paste the exact error message here. (obviously omit any info that is a security risk to share.
springbok
09-18-2008, 03:00 PM
INSERT command denied to user '(my username)'@'(my IP)' for table 'members'
Hopefully that helps.
UnlimitedMB
09-18-2008, 05:25 PM
I do not see how this is possible, we do not restrict insert command.
Obviously its a critical command, nothing would work without it.
Please delete the database and create a new one with the same name.
Tyler
09-18-2008, 06:52 PM
Are you trying to connect to the database server using an IP address, or are you connecting using 'mysql' as the server name?
Also, are you sure you are connecting from our server?
springbok
09-18-2008, 07:14 PM
Positive. Files are uploaded on your server, and nowhere in the script does it even call for the IP address. If you'd like to see the MySQL query in action (or rather failure) then just go to this address and try to register an account: http://springbok.ulmb.com/
Like I said, this script works flawlessly (so far) on my local wamp server, but after uploading everything and adjusting the connection settings, it fails. I'm pretty sure the error is somewhere in my script, but I just can't figure out where. If you want to see the code I use, let me know and I'll post it, but the script is very object oriented and would require my to include code from a couple files to show you where the problem is happening.
Edit: UnlimitedMB: I deleted and recreated the database with the same name, and the error still occurs.
Tyler
09-18-2008, 07:17 PM
The error says nothing about the insert command not working it clearly says:
Table '12526_project.groups' doesn't exist
EDIT: And now it looks like it is working.
springbok
09-19-2008, 03:26 AM
Any ideas?
UnlimitedMB
09-19-2008, 05:11 AM
The problem is you are using the command "INSERT INTO `project`.`members`"
But your database name is not "project" it is "12526_project"
So you get access denied error for trying to access a database you do not own.
FYI you do not need to specify database name in the query, and its recommended not to, precisely to avoid this issue.
"INSERT INTO `members`" will work just fine.
springbok
09-19-2008, 05:15 AM
Ha! Figures it's something simple as that... thanks for catching that! I'll fix it and try it out.
Edit: Success. Thanks for your assistance.
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.