URL to your eFiction: http://fictioning.net
Version of eFiction: 3.5.1
Have you bridged eFiction, if so with what?: No
Version of PHP: can be found out from your host 5
Version of MySQL: can be found out from your host
Have you searched for your problem: (yes/no) Yes
If so, what terms did you try: Error: (1146)
State the nature of your problem: Copy and paste any errors you are receiving.
A fatal MySQL error was encountered.
Query: SELECT count(chalid) FROM fanfiction_challenges
Error: (1146) Table 'xx_efiction.fanfiction_challenges' doesn't exist
Do you have a test account for us? No, I can't get into my account now.
I have just upgraded to 3.5.1
I successfully added a test story & logged in etc.
I then enabled "Challenges". It asked me to upgrade the Challenge. I did. (it displays Challenges - 1.4, when I click on the Challenges link but still 1.1 at the main modules list)
I then tried to set the Challenge to not accept anonymous challenges. The results is:
First error:
A fatal MySQL error was encountered.
Query: UPDATE fanfiction_settings SET anonchallenges = '1' WHERE sitekey = 'trdY6TufDc'
Error: (1054) Unknown column 'anonchallenges' in 'field list'
Trying to get to the main site:
A fatal MySQL error was encountered.
Query: SELECT count(chalid) FROM fanfiction_challenges
Error: (1146) Table 'xx_efiction.fanfiction_challenges' doesn't exist
I then backtracked and tried to uninstall the module. It told me that I have uninstalled it but I still get error:
A fatal MySQL error was encountered.
Query: SELECT count(chalid) FROM fanfiction_challenges
Error: (1146) Table 'xx_efiction.fanfiction_challenges' doesn't exist
I'm assuming it needs table(s) added but I'm not sure what or where.
Suggestions, please?
The challenges table looks nonexistent, but what you also should do is go into your database and go to fanfiction_modules. If there's a line for challenges, delete it. Then delete the challenges folder, and I think you'll have it uninstalled fully. I'm not too familiar with challenges in particular, though, so if you had to move any files into the main directory or anything, then delete those as well.
It needs the whole challenges table plus the settings in the settings table.
CREATE TABLE `fanfiction_challenges` (
`chalid` int(11) NOT NULL auto_increment,
`challenger` varchar(200) collate latin1_general_ci NOT NULL default '',
`uid` int(11) NOT NULL default '0',
`title` varchar(250) collate latin1_general_ci NOT NULL default '',
`catid` varchar(200) collate latin1_general_ci NOT NULL default '',
`characters` varchar(200) collate latin1_general_ci NOT NULL default '',
`summary` text collate latin1_general_ci NOT NULL,
`responses` int(11) NOT NULL default '0',
PRIMARY KEY (`chalid`),
KEY `title` (`catid`),
KEY `uid` (`uid`),
KEY `title_2` (`title`),
KEY `characters` (`characters`)
) ENGINE=MyISAM;
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/google/challenges.php");', 'google', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/otherresults.php");', 'otherresults', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/stats.php");', 'sitestats', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/deluser.php");', 'deluser', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/adminfunctions.php");', 'delcategory', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/seriestitle.php");', 'seriestitle', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/adminfunctions.php");', 'delchar', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/storyblock.php");', 'storyblock', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/seriesblock.php");', 'seriesblock', 'challenges');
INSERT INTO `fanfiction_codeblocks` (`code_text`, `code_type`, `code_module`) VALUES ('include(_BASEDIR."modules/challenges/authorof.php");', 'AO', 'challenges');
Don't forget to add your table prefix. I'd uninstall and reinstall after that as that doesn't add the panels. It should get your site back up though.
Thanks, Lyndsie and Tammy.
I found this post, and tried the SQL query suggested there...
It's created the table but I still get this error when I try to disallow anonymous challenges.
A fatal MySQL error was encountered.
Query: UPDATE fanfiction_settings SET anonchallenges = '0' WHERE sitekey = 'trdY6TufDc'
Error: (1054) Unknown column 'anonchallenges' in 'field list'
In my modules table, I've got two Challenges - 1.1 and 1.4 - I'm not sure if I should delete one (or both).
Tammy, as I've already added the fanfiction_challenges table, can I just do the second part of your query? And I'm not sure where the "table prefix" comes in (sorry, I'm a bit frazzed).
I think the entry for 1.1 is extra. If you're running 1.4, then that's the only one that should be in fanfiction_modules. If the "xx_efiction" is your hosting account name, then you don't have a prefix. I'm unclear on whether that's your prefix or not. Look in the setting in the admin control panel or at the names of your tables in the database. You want it to read exactly as they appear in there. A prefix is something that you could have added during install to allow you to have multiple eFiction installations in the same database, so there will be something in front of the 'fanfiction' part.
If you've got the table as displayed in Tammy's post, but not the entries in fanfiction_codeblocks, then you should run that part. Check in fanfiction_codeblocks first.
That error is saying that the 'anonchallenges' field doesn't exist. There's a modification that has to be done to fanfiction_settings, that wasn't.
Run this query
ALTER TABLE `PREFIXfanfiction_settings` ADD `anonchallenges` TINYINT( 1 ) NOT NULL
Thanks, Tammy! I'll run that query now. Edited to add: worked a charm (especially after I realised I'd forgotten to remove the PREFIX. Doh!)
Checked my settings and I don't have a table prefix. Phew.
Anyway, I ran the second part of Tammy's query and it reported success!
I've uninstalled the Challenges module, though the modules list still says "Challenges 1.1 Run Update | Options | Uninstall this module". However, when I click on "uninstall this module" it says "This module is not installed".
My modules table still shows both 1.1 and 1.4 listed. Should I delete either or both?
Edited again (sorry): I think I've done something wrong - the front end site info displays:
Challenges: 0
Challengers: 0
Challenges: 0
Challengers: 0
So, with all that done - how do I get the Challenges module installed again?
Okay, I think this is now fixed.
To remove the duplicated information at "Site info", I removed the duplicated "sitestats" item in the fanfiction_codeblocks table.
I then over wrote the entire modules directory, went to admin and "updated" the Challenges module. Then I set the anonymous challenges to "no" (yay! it worked).
Now I just have to figure out how to get the challenge to show up on the site - but that's another issue all together.
Thank you to Tammy and Lyndsie for all your help.
