网页开发

Items filtered by date: 3月 2021

估计用了用户表优化后出问题的人很多吧!很久没登录的用户重新登录后积分什么的都没了,哪怕重新发帖回帖,积分也不会变,用户组还会变成初始的用户组!还有QQ互联登录的用户重新登录就失效了,相当于重新注册新ID

论坛后台升级数据库:站长》数据库》升级

SQL
insert into pre_common_member select * from pre_common_member_archive;
insert into pre_common_member_count select * from pre_common_member_count_archive;
insert into pre_common_member_field_forum select * from pre_common_member_field_forum_archive;
insert into pre_common_member_field_home select * from pre_common_member_field_home_archive;
insert into pre_common_member_profile select * from pre_common_member_profile_archive;
insert into pre_common_member_status select * from pre_common_member_status_archive;

以上六条的意思就是把六个存档表中的东西合并到主表中。

然后再使用如下升级数据库:

SQL
TRUNCATE TABLE  `pre_common_member_archive`;
TRUNCATE TABLE  `pre_common_member_count_archive`;
TRUNCATE TABLE  `pre_common_member_field_forum_archive`;
TRUNCATE TABLE  `pre_common_member_field_home_archive`;
TRUNCATE TABLE  `pre_common_member_profile_archive`;
TRUNCATE TABLE  `pre_common_member_status_archive`;

 

以上六条的意思就是把六个存档表数据全部清空。

Published in 网络

经过用户表优化后,论坛不活跃用户将被转至存档表。这将意味着论坛在常规调用、查询都不会遍历这些存档表的数据。这也大大提高服务器工作效率,减少服务器负载。当然处于存档表的用户在执行一次登录操作后,数据会重新转入主表

这个登录是指论坛本身的用户登录,如果用第三方客户端 App 登录一般是不起作用的(除非 App 考虑到了这个情况)

 

common_member 是主表,common_member_archive 是存档表,这两个表的用户数相加即为 UC 用户表 ucenter_members 中的用户总和。

Published in 网络

关于CNERIS

CNERISYIF LINE公司的旗舰项目. 他是由IT行业不同区域的顶尖专家组成的. 我们的团队包括程序员,系统管理员,平面设计师, ERP集成服务。