Welcome to Geeklog, Anonymous Sunday, December 22 2024 @ 11:52 am EST
Geeklog Forums
Noob Help ? Error trying to post comment to poll- 1044: Access denied for user: SQL in question: LOC
Paul
Anonymous
I searched the FAQ and found my answer to this problem but I keep getting a syntax error every time I try to run the query:
GRANT LOCK TABLES ON .* to @
What am I screwing up here? should be (my site)?
I tried it with & but got an error both ways.
The error I received iis below:
Error
SQL-query :
GRANT LOCK TABLES ON @
MySQL said:
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 ' @ ' at
The solution given in the FAQ was:
You might see this message in your error.log:
1044: Access denied for user: 'xxx@%' to database 'xxx'. SQL in question: LOCK TABLES gl_comments WRITE
Possible solutions:
0. Hosted Environment: Tell your host that you want "LOCK TABLE" priveleges or you'll take your business else where. Some hosting providers will stall or say they can't set it for reason XXX. That is just not true. Most hosts provide this capability.
1. If you have mysql administrative privileges to grant database level rights (usually this requires being the mysql root user) use the following SQL to grant lock table priveleges:
GRANT LOCK TABLES ON .* to @
2. Remove all the "LOCK TABLE" "UNLOCK TABLE" SQL calls from comment.php. This should be okay if you have a low traffice site, but opens up the possiblity of corruption if two or more users try to save or delete comments at the same time.
3. Upgrade to InnoDB tables. There is a script in the admin directory to do this. Then, in comment.php, change every instance of "LOCK TABLE XXX" to "START TRANSACTION" and every instance of "UNLOCK TABLE XXX" to "COMMIT". The only downside to this is that it is not well tested and will only work with InnoDB tables.
Is it possible I have a webhost that won't give me "LOCK TABLE" priveleges Some hosting providers will stall or say they can't set it for reason XXX.
If that is causing the error I will have to call them today.
Any help would be great!
Thanks
GRANT LOCK TABLES ON .* to @
What am I screwing up here? should be (my site)?
I tried it with & but got an error both ways.
The error I received iis below:
Error
SQL-query :
GRANT LOCK TABLES ON @
MySQL said:
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 ' @ ' at
The solution given in the FAQ was:
You might see this message in your error.log:
1044: Access denied for user: 'xxx@%' to database 'xxx'. SQL in question: LOCK TABLES gl_comments WRITE
Possible solutions:
0. Hosted Environment: Tell your host that you want "LOCK TABLE" priveleges or you'll take your business else where. Some hosting providers will stall or say they can't set it for reason XXX. That is just not true. Most hosts provide this capability.
1. If you have mysql administrative privileges to grant database level rights (usually this requires being the mysql root user) use the following SQL to grant lock table priveleges:
GRANT LOCK TABLES ON .* to @
2. Remove all the "LOCK TABLE" "UNLOCK TABLE" SQL calls from comment.php. This should be okay if you have a low traffice site, but opens up the possiblity of corruption if two or more users try to save or delete comments at the same time.
3. Upgrade to InnoDB tables. There is a script in the admin directory to do this. Then, in comment.php, change every instance of "LOCK TABLE XXX" to "START TRANSACTION" and every instance of "UNLOCK TABLE XXX" to "COMMIT". The only downside to this is that it is not well tested and will only work with InnoDB tables.
Is it possible I have a webhost that won't give me "LOCK TABLE" priveleges Some hosting providers will stall or say they can't set it for reason XXX.
If that is causing the error I will have to call them today.
Any help would be great!
Thanks
10
15
Quote
Paul
Anonymous
Ok I don't know what happened but in my last post I had the line for the SQL written exactly as I entered it but when I submitted the post a lot of the sentence is missing. So if for some reason I can't type the exact syntax I'm going to have a hard time explaining the problem. Anyway I tried to give as much info as I had.
Here is a link to the answer that I couldn't get to work:
http://www.geeklog.net/faqman/index.php?op=view&t=51
Here is a link to the answer that I couldn't get to work:
http://www.geeklog.net/faqman/index.php?op=view&t=51
10
10
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by Paul: Ok I don't know what happened but in my last post I had the line for the SQL written exactly as I entered it but when I submitted the post a lot of the sentence is missing.
Try using the forum's CODE button.
Not sure why you quoted the entire FAQ entry above and where in all that your actual question is. Please state it again ...
bye, Dirk
11
10
Quote
All times are EST. The time is now 11:52 am.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content