Forum Moderators: coopster

Message Too Old, No Replies

MySql server error

         

Cubbie

7:03 pm on Apr 10, 2008 (gmt 0)

10+ Year Member



Heya everyone!

I'm bummed at this error message that came up just today - you can view it at my site here: <snip>

The error says...

WordPress database error: [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 'A' at line 1]

SELECT t.*, tt.* FROM wp_ngg_gallery AS t INNER JOIN wp_ngg_pictures AS tt ON t.gid = tt.galleryid WHERE t.gid = '2' AND tt.exclude != 1 ORDER BY tt.A A

I do not know what happened to it. Before today, it was perfectly fine. Any ideas?

Thanks so much in advance!

[edited by: eelixduppy at 7:17 pm (utc) on April 10, 2008]
[edit reason] no URLs, please [/edit]

eelixduppy

7:20 pm on Apr 10, 2008 (gmt 0)



Hello and Welcome to WebmasterWorld!

You have an extra A at the end of your query that doesn't belong there. You should remove it to get the following:


SELECT t.*, tt.* FROM wp_ngg_gallery AS t INNER JOIN wp_ngg_pictures AS tt ON t.gid = tt.galleryid WHERE t.gid = '2' AND tt.exclude != 1 ORDER BY tt.A

Or replace it with what I'd imagine was there beofre there was an error:


SELECT t.*, tt.* FROM wp_ngg_gallery AS t INNER JOIN wp_ngg_pictures AS tt ON t.gid = tt.galleryid WHERE t.gid = '2' AND tt.exclude != 1 ORDER BY tt.A [b]ASC[/b]

Cubbie

4:24 am on Apr 11, 2008 (gmt 0)

10+ Year Member



Wow, thank you, eelixduppy!

Alright! I'll go and have a try at it!

Cubbie

6:44 am on Apr 11, 2008 (gmt 0)

10+ Year Member



Wait, ummm, I'm not sure as to where I should find that query! o.O

jatar_k

3:22 pm on Apr 11, 2008 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



what page/script were you trying to access when you got the error? That would be the place to start.

If you can't find it in that file then you should probably look through all the files that are included by that script.

if you have commend line access/knowledge you could just grep the files for that query