织梦DedeCms如何批量修改文章发布时间

2017-04-13 14:27:16 dedecms

当我们购买一个网站源码里面的文章发布时间日期很早了,一个一个修改是不现实的,那么就需要批量修改文章发布时间了。

1、首先是SQL语句

update dede_archives set pubdate= 1308240000 where id>=1 and id<=10;

update dede_archives set senddate= 1335542400 where id>=1 and id<=10;

解释一下上面两行代码,功能就是把ID号从1到10的文章发布日期由2011年6月17日修改到2012年4月28日。

其中“pubdate= 1308240000 ”和“senddate= 1335542400” 中的数字为“Unix时间(Unixtimestamp) ” 这个把日期转换成时间戳的地址,大家http://tool.chinaz.com/Tools/unixtime.aspx去转换。

2、执行SQL命令

后台->系统->SQL命令行工具