SQL 服务器中的 TimeStamp 和 DateTime 有什么区别?
What is the difference between TimeStamp and DateTime in SQL Server?
在SQL服务器中,有TimeStamp类型,我什么时候使用它,而不是简单的DateTime?
时间戳有什么用?我听说这是为了保证日期时间不会被更改,就像邮票一样。是吗?
timestamp 是自动生成的并且是唯一的。这已被弃用。
注释来自 Microsoft
The timestamp syntax is deprecated. This feature will be removed in a
future version of Microsoft SQL Server. Avoid using this feature in
new development work, and plan to modify applications that currently
use this feature.
datetime是一种处理日期和时间的数据类型
在SQL服务器中,有TimeStamp类型,我什么时候使用它,而不是简单的DateTime?
时间戳有什么用?我听说这是为了保证日期时间不会被更改,就像邮票一样。是吗?
timestamp 是自动生成的并且是唯一的。这已被弃用。
注释来自 Microsoft
The timestamp syntax is deprecated. This feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.
datetime是一种处理日期和时间的数据类型