sql server 2005 创建表时间修改

[复制链接]
查看11 | 回复4 | 2013-4-15 08:35:57 | 显示全部楼层 |阅读模式
这个用到update就可以修改为当前时间了,假设为student表,时间字段为entertimeupdatea set entertime=convert(char(10),entertime,120)即可修改为当前时间。...
回复

使用道具 举报

千问 | 2013-4-15 08:35:57 | 显示全部楼层
系统默认的创建数据表的日期,不能修改,除非删除后重新创建。...
回复

使用道具 举报

千问 | 2013-4-15 08:35:57 | 显示全部楼层
操作系统数据库master sp_configure 'allow updates',1reconfigure with overridegoupdate sysobjects set crdate='2013-4-15' where id=object_id('表名')gosp_configure 'allow updates'...
回复

使用道具 举报

千问 | 2013-4-15 08:35:57 | 显示全部楼层
update 表名 set 时间列=cast(convert(char(10),getdate() ,120) as datetime)...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行