Solved: 3 Years, 5 Months, 2 Weeks ago Attachmentdatabase issues
#1
Solved: 3 Years, 5 Months, 2 Weeks ago
My hosts were giving me hassle about bandwidth issues and while I was looking at solutions I messed up my attachment database. I thought I had figured it out and fixed it but now no one can add attachments, option works but the attachment simple doesnt show up.

Could someone maybe have a look if I supplied admin access? Matt helped me out before
Reply
#2
Solved: 3 Years, 5 Months, 2 Weeks ago
What do you mean you've messed up the attachment database? Did you delete the table or alter the structure or something?
Plugin Count: I lost count.
Public Plugins are available here.
Official GitHub.
Please do not PM me for support unless asked to.
Reply
#3
Solved: 3 Years, 5 Months, 2 Weeks ago
(2017-10-08, 04:07 PM)Wires Wrote: What do you mean you've messed up the attachment database? Did you delete the table or alter the structure or something?

Yeah, I meant to empty it and dropped it instead. Created a new database and it seemed to work but now, nope.
Reply
#4
Solved: 3 Years, 5 Months, 2 Weeks ago
Try the following for the latest version of MyBB:

DROP TABLE IF EXISTS `mybb_attachments`;
CREATE TABLE `mybb_attachments` (
  `aid` int(10) unsigned NOT NULL AUTO_INCREMENT,
  `pid` int(10) unsigned NOT NULL DEFAULT '0',
  `posthash` varchar(50) NOT NULL DEFAULT '',
  `uid` int(10) unsigned NOT NULL DEFAULT '0',
  `filename` varchar(120) NOT NULL DEFAULT '',
  `filetype` varchar(120) NOT NULL DEFAULT '',
  `filesize` int(10) unsigned NOT NULL DEFAULT '0',
  `attachname` varchar(120) NOT NULL DEFAULT '',
  `downloads` int(10) unsigned NOT NULL DEFAULT '0',
  `dateuploaded` int(10) unsigned NOT NULL DEFAULT '0',
  `visible` tinyint(1) NOT NULL DEFAULT '0',
  `thumbnail` varchar(120) NOT NULL DEFAULT '',
  PRIMARY KEY (`aid`),
  KEY `pid` (`pid`,`visible`),
  KEY `uid` (`uid`)
) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;
Plugin Count: I lost count.
Public Plugins are available here.
Official GitHub.
Please do not PM me for support unless asked to.
Reply
#5
Solved: 3 Years, 5 Months, 2 Weeks ago
Im sorry, Am I running this somewhere or using the values to create a new database via phpmyadmin?
Reply
#6
Solved: 3 Years, 5 Months, 2 Weeks ago
(2017-10-10, 02:27 PM)ESForum Wrote: Im sorry, Am I running this somewhere or using the values to create a new database via phpmyadmin?

Run the above as a query in your current database via PhpMyAdmin.
Plugin Count: I lost count.
Public Plugins are available here.
Official GitHub.
Please do not PM me for support unless asked to.
Reply
#7
Solved: 3 Years, 5 Months, 2 Weeks ago
ran that I think but no difference

In my orphanat attachments it says "Not in attachments table" as the reason for being orphaned
Reply
#8
Solved: 3 Years, 5 Months, 2 Weeks ago
This only create a new table for your attachments but not link to the old one... this will be hard work to restore this manualy if you don't have backups.
Paid support or developement: www.broatcast-consulting.de
All other: blog.broatcast.de

[Image: EbbMWfN.png]

Reply
#9
Solved: 3 Years, 5 Months, 2 Weeks ago
I dont have anything in there, I dont have any attachments so creating a new tables fine once poeple can start adding attachments again afterwards
Reply
#10
Solved: 3 Years, 5 Months, 2 Weeks ago
Then you are lucky Wink... dont forget to make constantly backups.. specialy before you try something out or change something or install something.... ever ever ever make a backup befor.
Paid support or developement: www.broatcast-consulting.de
All other: blog.broatcast.de

[Image: EbbMWfN.png]

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)