MyBB Community Forums

Full Version: Please Help - MySQL Related
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I get this error:
MySQL error: 1146
Table 'pspalert_forum.mybbundergroundloungeforum2_smilies' doesn't exist
Query: SELECT COUNT(*) as smilies FROM mybbundergroundloungeforum2_smilies

I accidently deleted it, while trying to do something on a back up.

Can I re-install it, but just upload the config.php and functions.php and it should be the same, all the posts, members, forums etc...
Quote:I accidently deleted it, while trying to do something on a back up.
and what was that? did you mean your db?
of course you can restore it if you already have a backup..
otherwise, am sorry to say that noway to restore everything with out re-do it one by one
Run this in phpMyAdmin to restore that table specifically:

CREATE TABLE mybbundergroundloungeforum2_smilies (
  sid smallint unsigned NOT NULL auto_increment,
  name varchar(120) NOT NULL default '',
  find varchar(120) NOT NULL default '',
  image varchar(220) NOT NULL default '',
  disporder smallint unsigned NOT NULL default '0',
  showclickable int(1) NOT NULL default '0',
  PRIMARY KEY  (sid)
) TYPE=MyISAM;

And after you run the above, you can run this:
INSERT INTO `mybbundergroundloungeforum2_smilies` (`sid`, `name`, `find`, `image`, `disporder`, `showclickable`) VALUES
(1, 'Smile', ':)', 'images/smilies/smile.gif', 1, 'yes'),
(2, 'Wink', ';)', 'images/smilies/wink.gif', 2, 'yes'),
(3, 'Cool', ':cool:', 'images/smilies/cool.gif', 3, 'yes'),
(4, 'Big Grin', ':D', 'images/smilies/biggrin.gif', 4, 'yes'),
(5, 'Tongue', ':P', 'images/smilies/tongue.gif', 5, 'yes'),
(6, 'Rolleyes', ':rolleyes:', 'images/smilies/rolleyes.gif', 6, 'yes'),
(7, 'Shy', ':shy:', 'images/smilies/shy.gif', 7, 'yes'),
(8, 'Sad', ':(', 'images/smilies/sad.gif', 8, 'yes'),
(9, 'At', ':at:', 'images/smilies/at.gif', 9, 'no');

How do I run that??

NVM I got it. Thanks DenissTT!! Saved my forum.
When I try to run the second thing I get this error

Error
SQL query:

INSERT INTO mybbundergroundloungeforum2_smilies ( sid , name , find , image , disporder , showclickable )
VALUES ( 1, 'Smile', 'Smile', 'images/smilies/smile.gif', 1, 'yes' ) , ( 2, 'Wink', 'Wink', 'images/smilies/wink.gif', 2, 'yes' ) , ( 3, 'Cool', 'Cool', 'images/smilies/cool.gif', 3, 'yes' ) , ( 4, 'Big Grin', 'Big Grin', 'images/smilies/biggrin.gif', 4, 'yes' ) , ( 5, 'Tongue', 'Toungue', 'images/smilies/tongue.gif', 5, 'yes' ) , ( 6, 'Rolleyes', 'Rolleyes', 'images/smilies/rolleyes.gif', 6, 'yes' ) , ( 7, 'Shy', 'Shy', 'images/smilies/shy.gif', 7, 'yes' ) , ( 8, 'Sad', 'Sad', 'images/smilies/sad.gif', 8, 'yes' ) , ( 9, 'At', 'At', 'images/smilies/at.gif', 9, 'no' )

MySQL said:

#1062 - Duplicate entry '1' for key 1
Means you already have smilies in your forum, and you probably don't need to run query 2.