after a server update i keep getting the error "Error fetching Recent Topics: 1054 Unknown column 't.ID_TOPIC' in 'on clause'" from the recent topics module.
when i'm not logged in, i get the usual topics listing, but as a logged in user i get said error message.
i run joomla_smf 1.1beta within joomla 1.0.7 with smf 1.1rc2. as far as i can tell, the database is intact, smf-table-prefix is set correctly, login works.
can anyone enlighten me as to where i should look for a solution to this?
hmmmm, haven't seen that one before. Check the smf_topics table to make sure there is a ID_TOPIC column in your db. Thats specifically what the error message is stating, that the ID_TOPIC column is unknown, which is impossible if SMF is working correctly.
Also, update to Joomla-SMF 1.1RC1, the betas were just that, beta.
damn. i feel st$p$d. i really thought i downloaded the latest version. snap.
er... i just rechecked. joomla-smf 1.1beta is the latest one in the downloads-section.
edit 2: ok. i was being dumb. thank you for not yelling at me. installed 1.1rc1 now. the problem's still there, though. the column the thing complains about not being there exists.
« Last Edit: February 15, 2006, 06:11:13 AM by gtz »
I wonder if an error is occurring but we are still getting the posts. I hadn't thought of that. Try commenting the 'return false' in the following block of code on or around line 152 of the mod.
I wonder if an error is occurring but we are still getting the posts. I hadn't thought of that. Try commenting the 'return false' in the following block of code on or around line 152 of the mod.
i just wanted to mention that un- & re-installing both joomla-smf and the recent topics module did not make this problem go away.
as i said, the database is dandy and quite as it should be, joomla working fine, smf doing great. i do have the feeling that the smf-table-prefix gets messed up, somehow. i'll check.
edit: after some research, it boils down to this query screwing up:
Code:
SELECT mem.realName, m.posterTime, m2.subject, t.ID_TOPIC, t.ID_MEMBER_UPDATED, t.ID_LAST_MSG, m.ID_MSG_MODIFIED, m.ID_BOARD, b.name AS bName, t.numReplies, m.posterName AS memberName, " . ($user_info['is_guest'] ? "0" : "IFNULL(lt.ID_MSG, IFNULL(lmr.ID_MSG, -1)) + 1") . " AS new_from FROM ({$smf_tprefix}members AS mem, {$smf_tprefix}topics AS t, {$smf_tprefix}messages AS m, {$smf_tprefix}messages AS m2, {$smf_tprefix}boards AS b " . (!$user_info['is_guest'] ? " LEFT JOIN {$smf_tprefix}log_topics AS lt ON (lt.ID_TOPIC = t.ID_TOPIC AND lt.ID_MEMBER = '".$ID_MEMBER."') LEFT JOIN {$smf_tprefix}log_mark_read AS lmr ON (lmr.ID_BOARD = t.ID_BOARD AND lmr.ID_MEMBER = '".$ID_MEMBER."')" : "") . ") WHERE t_t.ID_BOARD = m.ID_BOARD AND t.ID_BOARD = b.ID_BOARD" . (empty($exclude_boards) ? '' : " AND t.ID_BOARD NOT IN (" . implode(', ', $exclude_boards) . ")") . " AND t.ID_LAST_MSG = m.ID_MSG AND t.ID_FIRST_MSG = m2.ID_MSG AND mem.memberName = m.posterName AND $user_info[query_see_board] ORDER BY m.ID_MSG DESC LIMIT ".$limit
the point at which it falls apart is the first "LEFT JOIN"-row:
Code:
LEFT JOIN {$smf_tprefix}log_topics AS lt ON (lt.ID_TOPIC = t.ID_TOPIC AND lt.ID_MEMBER = '".$ID_MEMBER."')
when i query the databse directly to select t.ID_TOPIC from smf_topics as t, all works fine. as soon as i join this table with anything, it blows up into my face.
i'm beginning to suspect, the database might be corrupt. alas, a repair table on smf_topics claimed it was ok.
« Last Edit: February 15, 2006, 12:35:38 PM by gtz »
when i query the databse directly to select t.ID_TOPIC from smf_topics as t, all works fine. as soon as i join this table with anything, it blows up into my face.
i'm beginning to suspect, the database might be corrupt. alas, a repair table on smf_topics claimed it was ok.
hmmm, well the query is pretty much verbatim from SMF so I am unsure why it isn't working for you. It is working for me and others so I suspect it must be something unique to your site. Maybe your db is corrupt? If I can help just let me know, but at this point I am not sure what the problem could be.
Joomla Hacks is a Joomla Components, Joomla Modules, Joomla Templates, & Joomla Mambots resource portal. None of the text or images in this public website may be copied without the expressed written consent of the authors. Copyright 2005 by JoomlaHacks.com. Powered by Joomla. All rights reserved. Terms of Use