Merge pull request #28845 from taosdata/docs/TD-32946

docs:[TD-32946] Modify the description of time and date functions.
This commit is contained in:
Shengliang Guan 2024-11-21 15:34:46 +08:00 committed by GitHub
commit a0560f8bcd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 11 additions and 11 deletions

View File

@ -422,7 +422,7 @@ CAST(expr AS type_name)
TO_ISO8601(expr [, timezone])
```
**Description**: The ISO8601 date/time format converted from a UNIX timestamp, plus the timezone. You can specify any time zone with the timezone parameter. If you do not enter this parameter, the time zone on the client is used.
**Description**: The ISO8601 date/time format converted from a timestamp, plus the timezone. You can specify any time zone with the timezone parameter. If you do not enter this parameter, the time zone on the client is used.
**Return value type**: VARCHAR
@ -466,7 +466,7 @@ return_timestamp: {
}
```
**Description**: UNIX timestamp converted from a string of date/time format
**Description**: timestamp converted from a string of date/time format
**Return value type**: BIGINT, TIMESTAMP

View File

@ -1065,7 +1065,7 @@ CAST(expr AS type_name)
TO_ISO8601(expr [, timezone])
```
**功能说明**:将 UNIX 时间戳转换成为 ISO8601 标准的日期时间格式并附加时区信息。timezone 参数允许用户为输出结果指定附带任意时区信息。如果 timezone 参数省略,输出结果则附带当前客户端的系统时区信息。
**功能说明**:将时间戳转换成为 ISO8601 标准的日期时间格式并附加时区信息。timezone 参数允许用户为输出结果指定附带任意时区信息。如果 timezone 参数省略,输出结果则附带当前客户端的系统时区信息。
**返回结果数据类型**VARCHAR 类型。
@ -1109,7 +1109,7 @@ return_timestamp: {
}
```
**功能说明**:将日期时间格式的字符串转换成为 UNIX 时间戳。
**功能说明**:将日期时间格式的字符串转换成为时间戳。
**返回结果数据类型**BIGINT, TIMESTAMP。
@ -1257,8 +1257,8 @@ TIMEDIFF(expr1, expr2 [, time_unit])
**返回结果类型**BIGINT。
**适用数据类型**
- `expr1`:表示 UNIX 时间戳的 BIGINT, TIMESTAMP 类型,或符合日期时间格式的 VARCHAR, NCHAR 类型。
- `expr2`:表示 UNIX 时间戳的 BIGINT, TIMESTAMP 类型,或符合日期时间格式的 VARCHAR, NCHAR 类型。
- `expr1`:表示时间戳的 BIGINT, TIMESTAMP 类型,或符合 ISO8601/RFC3339 标准的日期时间格式的 VARCHAR, NCHAR 类型。
- `expr2`:表示时间戳的 BIGINT, TIMESTAMP 类型,或符合 ISO8601/RFC3339 标准的日期时间格式的 VARCHAR, NCHAR 类型。
- `time_unit`:见使用说明。
**嵌套子查询支持**:适用于内层查询和外层查询。
@ -1301,7 +1301,7 @@ use_current_timezone: {
**返回结果数据类型**TIMESTAMP。
**应用字段**:表示 UNIX 时间戳的 BIGINT, TIMESTAMP 类型,或符合日期时间格式的 VARCHAR, NCHAR 类型。
**应用字段**:表示时间戳的 BIGINT, TIMESTAMP 类型,或符合 ISO8601/RFC3339 标准的日期时间格式的 VARCHAR, NCHAR 类型。
**适用于**:表和超级表。
@ -1364,7 +1364,7 @@ WEEK(expr [, mode])
**返回结果类型**BIGINT。
**适用数据类型**
- `expr`:表示 UNIX 时间戳的 BIGINT, TIMESTAMP 类型,或符合日期时间格式的 VARCHAR, NCHAR 类型。
- `expr`:表示时间戳的 BIGINT, TIMESTAMP 类型,或符合 ISO8601/RFC3339 标准的日期时间格式的 VARCHAR, NCHAR 类型。
- `mode`0 - 7 之间的整数。
**嵌套子查询支持**:适用于内层查询和外层查询。
@ -1424,7 +1424,7 @@ WEEKOFYEAR(expr)
**返回结果类型**BIGINT。
**适用数据类型**:表示 UNIX 时间戳的 BIGINT, TIMESTAMP 类型,或符合日期时间格式的 VARCHAR, NCHAR 类型。
**适用数据类型**:表示时间戳的 BIGINT, TIMESTAMP 类型,或符合 ISO8601/RFC3339 标准的日期时间格式的 VARCHAR, NCHAR 类型。
**嵌套子查询支持**:适用于内层查询和外层查询。
@ -1451,7 +1451,7 @@ WEEKDAY(expr)
**返回结果类型**BIGINT。
**适用数据类型**:表示 UNIX 时间戳的 BIGINT, TIMESTAMP 类型,或符合日期时间格式的 VARCHAR, NCHAR 类型。
**适用数据类型**:表示 表示时间戳的 BIGINT, TIMESTAMP 类型,或符合 ISO8601/RFC3339 标准的日期时间格式的 VARCHAR, NCHAR 类型。
**嵌套子查询支持**:适用于内层查询和外层查询。
@ -1478,7 +1478,7 @@ DAYOFWEEK(expr)
**返回结果类型**BIGINT。
**适用数据类型**:表示 UNIX 时间戳的 BIGINT, TIMESTAMP 类型,或符合日期时间格式的 VARCHAR, NCHAR 类型。
**适用数据类型**:表示时间戳的 BIGINT, TIMESTAMP 类型,或符合 ISO8601/RFC3339 标准的日期时间格式的 VARCHAR, NCHAR 类型。
**嵌套子查询支持**:适用于内层查询和外层查询。