PDA

View Full Version : mysql error number: 1146


OrangeFlea
03-26-2005, 11:35 PM
How do I fix this problem? Board's been down all day. Was I hacked?

Database error in vBulletin 3.0.3:

Invalid SQL:
SELECT
userfield.*, usertextfield.*, user.*, UNIX_TIMESTAMP(passworddate) AS
passworddate,
IF(displaygroupid=0, user.usergroupid, displaygroupid) AS
displaygroupid,
language.phrasegroup_holiday AS phrasegroup_holiday,
language.phrasegroup_shoutbox AS phrasegroup_shoutbox,
language.phrasegroup_global AS phrasegroup_global,
language.options AS lang_options,
language.languagecode AS lang_code,
language.charset AS lang_charset,
language.locale AS lang_locale,
language.imagesoverride AS lang_imagesoverride,
language.dateoverride AS lang_dateoverride,
language.timeoverride AS lang_timeoverride,
language.registereddateoverride AS lang_registereddateoverride,
language.calformat1override AS lang_calformat1override,
language.calformat2override AS lang_calformat2override,
language.logdateoverride AS lang_logdateoverride,
language.decimalsep AS lang_decimalsep,
language.thousandsep AS lang_thousandsep
FROM user AS user
LEFT JOIN userfield AS userfield ON (user.userid = userfield.userid)
LEFT JOIN usertextfield AS usertextfield ON (usertextfield.userid =
user.userid) INNER JOIN language AS language ON (language.languageid =
IF(user.languageid = 0, 1, user.languageid))
WHERE user.userid = 257

mysql error: Table 'xxxx_forum.user' doesn't exist

mysql error number: 1146

Date: Saturday 26th of March 2005 06:44:10 PM
Script: http://www.xxx.com/forum/
Referer:
IP Address: xxx.xxx.xxx.xxx


****************************

I'm also getting this error:

Database error in vBulletin 3.0.3:

Invalid SQL:
SELECT post.postid, post.pagetext, IFNULL( user.username , post.username
) AS username, dateline
FROM post AS post
LEFT JOIN user AS user ON (user.userid = post.userid)
LEFT JOIN deletionlog AS deletionlog ON (deletionlog.primaryid =
post.postid AND deletionlog.type = 'post')
WHERE threadid = 502
AND visible = 1
AND deletionlog.primaryid IS NULL

ORDER BY dateline ASC
LIMIT 0, 250

mysql error: Table 'xxxxx_forum.post' doesn't exist

mysql error number: 1146

Date: Saturday 26th of March 2005 08:35:17 PM
Script: http://www.xxxxx.com/forum/archive/index.php/xxxx.html
Referer:
IP Address: xxxxxxxxx



NOTE: I was in the middle of adding avatars and such when this happened (wasn't messing with the database). Also, the last hack I installed was the "swear word" filter hack

miz
03-26-2005, 11:40 PM
change

FROM user AS user
LEFT JOIN userfield AS userfield ON (user.userid = userfield.userid)
LEFT JOIN usertextfield AS usertextfield ON (usertextfield.userid =
user.userid) INNER JOIN language AS language ON (language.languageid


to :

FROM ".TABLE_PREFIX."user AS user
LEFT JOIN ".TABLE_PREFIX."userfield AS userfield ON (user.userid = userfield.userid)
LEFT JOIN ".TABLE_PREFIX."usertextfield AS usertextfield ON (usertextfield.userid =
user.userid) INNER JOIN ".TABLE_PREFIX."language AS language ON (language.languageid

OrangeFlea
03-26-2005, 11:43 PM
You mean run a query?

Where do I paste the revision and do I replace the values in red with my database and prefix (or do I paste it exactly as you show it?)?

miz
03-27-2005, 12:09 AM
on the file itself

OrangeFlea
03-27-2005, 12:11 AM
Which file exactly? Please?

I think the problem is in my functions.php. But the line you pointed to reflects the changed version already.

PS: I checked the index.php. None of those values are there.

PPS: Willing to pay $20 for anyone who can fix this. Please PM me.

tnguy3n
03-27-2005, 04:27 AM
You just need to add TABLE_PREFIX to your query.