如果你的VPS或服务器时间突然不准对uc/uch/dz中的数据进行恢复
作者:airzen 日期:2010-01-07
一个朋友的VPS突然变成2017年了,这样直接导致好多的日期字段都是2017年的,即使你将服务器时间调回正确,数据确实是已经被记录了,犹其是一些按日期排行的数据会一直持续的挂在首页直到2017年。哈哈。。这实在有点烦人。。
下面说一下我的解决方法,其实很简单就是将日期差减回去就行了。
这个数字是当前的时间,你可以通过time函数得到 1272263385
select * from `uchome_notification` where dateline >1272263385
然后找到表中日期最大的那个日期,相减得到日期差 247665335
下面是对相关表数据进行更新
update `uchome_notification` set dateline = dateline -247665335
where dateline >1272263385
update uchome_friend
set dateline = dateline -247665335
where dateline >1272263385
update uchome_vistor
set dateline = dateline -247665335
where dateline >1272263385
update uchome_space
set updatetime = updatetime - 247665335
where updatetime >1272263385
附康盛UCHome相关的数据字典:
点击下载此文件,改名为htm即可查看。
上一篇
下一篇

文章来自:
Tags: