I have added the script below although note you will need to (a) replace the ‘xxx’ with your table prefix and (b) change the engine if you are not using myISAM tables.
There is nothing in the upgrade script at all. All that happens during thje upgrade process is that the build and version numbers are updated in the sfoptions table. So I am afraid I have no idea what may have happened to your table…. Do you have any ideas?
Of course – the table creation can not replace any missing data. Note that I have included any new columns created by SP plugins as I am unsure what, if any, you may be using.
CREATE TABLE `xxx_sfforums` (
`forum_id` bigint(20) NOT NULL AUTO_INCREMENT,
`forum_name` varchar(200) COLLATE utf8mb4_unicode_ci NOT NULL,
`group_id` bigint(20) NOT NULL,
`forum_seq` int(4) DEFAULT NULL,
`forum_desc` mediumtext COLLATE utf8mb4_unicode_ci,
`forum_status` int(4) NOT NULL DEFAULT '0',
`forum_slug` varchar(200) COLLATE utf8mb4_unicode_ci NOT NULL,
`forum_rss` mediumtext COLLATE utf8mb4_unicode_ci,
`forum_icon` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`post_id` bigint(20) DEFAULT NULL,
`topic_count` mediumint(8) DEFAULT '0',
`forum_rss_private` smallint(1) NOT NULL DEFAULT '0',
`topic_status_set` bigint(20) DEFAULT '0',
`post_count` mediumint(8) DEFAULT '0',
`post_ratings` smallint(1) NOT NULL DEFAULT '0',
`use_tags` smallint(1) NOT NULL DEFAULT '1',
`parent` bigint(20) NOT NULL DEFAULT '0',
`children` mediumtext COLLATE utf8mb4_unicode_ci,
`forum_message` mediumtext COLLATE utf8mb4_unicode_ci,
`in_sitemap` smallint(1) NOT NULL DEFAULT '1',
`post_id_held` bigint(20) DEFAULT NULL,
`post_count_held` mediumint(8) DEFAULT '0',
`forum_icon_new` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`topic_icon` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`topic_icon_new` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`forum_email` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`polls` smallint(1) NOT NULL DEFAULT '0',
`keywords` varchar(256) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`forum_disabled` smallint(1) NOT NULL DEFAULT '0',
`topic_icon_locked` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`forum_icon_locked` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`topic_icon_pinned` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`feature_image` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`last_topic_id` bigint(20) NOT NULL DEFAULT '0',
`topic_icon_pinned_new` varchar(50) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`permalink_slug` varchar(1000) COLLATE utf8mb4_unicode_ci NOT NULL,
`forum_hide_posters` smallint(1) NOT NULL DEFAULT '0',
PRIMARY KEY (`forum_id`),
KEY `group_id_idx` (`group_id`),
KEY `forum_slug_idx` (`forum_slug`),
KEY `post_id_idx` (`post_id`),
KEY `topic_status_set_idx` (`topic_status_set`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;