If you want to preserve the fractional seconds, you'd use a TIMESTAMP(3)
(or just a TIMESTAMP
). If you don't care about the fractional seconds, you'd use a DATE
.
SQL Server datetime to Oracle
-
24-06-2022 - |
题
If you have in SQL Server DATETIME
, what will this be in Oracle?
DATE
, where you loose the fractional parts of a second or better TIMESTAMP(3)
?
解决方案 2
其他提示
From here: http://docs.oracle.com/cd/B19306_01/server.102/b14225/ch4datetime.htm
DATE contains the following
- Year
- Month
- Day
- Hour
- Minute
- Second
Whereas TIMESTAMP will also contain fractional seconds. With TIMESTAMP(n) you can specify n as a number between 0 and 9 for how many digits of precision, the default is 6.
不隶属于 StackOverflow