What is the meaning of the following SQL Server declaration: datetime2(7)?(以下 SQL Server 声明的含义是什么:datetime2(7)?)
问题描述
在 SQL Server 查询中,有:datetime2(7).
我知道datetime2,但我不明白(7).
Inside a SQL Server query, there is: datetime2(7).
I know datetime2, but I don't understand (7).
你能解释一下(7)的含义吗?
Can you explain the meaning of (7)?
推荐答案
datetime2 [ (fractional seconds precision) ]
根据 MSDN 文档,这是小数秒精度.
It's the fractional seconds precision according to the MSDN documentation.
http://msdn.microsoft.com/en-us/library/bb677335.aspx一个>
这是微软4的例子:
DECLARE @datetime2 datetime2(4) = '12-10-25 12:32:10.1234';
所以我假设 7 是:
DECLARE @datetime2 datetime2(7) = '12-10-25 12:32:10.1234567';
这篇关于以下 SQL Server 声明的含义是什么:datetime2(7)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:以下 SQL Server 声明的含义是什么:datetime2(7)?
基础教程推荐
- 如何根据该 XML 中的值更新 SQL 中的 XML 2021-01-01
- 在 MySQL 中:如何将表名作为存储过程和/或函数参数传递? 2021-01-01
- oracle区分大小写的原因? 2021-01-01
- 在多列上分布任意行 2021-01-01
- MySQL 中的类型:BigInt(20) 与 Int(20) 2021-01-01
- mysql选择动态行值作为列名,另一列作为值 2021-01-01
- 二进制文件到 SQL 数据库 Apache Camel 2021-01-01
- 什么是 orradiag_<user>文件夹? 2022-01-01
- 如何在 SQL 中将 Float 转换为 Varchar 2021-01-01
- 表 './mysql/proc' 被标记为崩溃,应该修复 2022-01-01
