Lưu ý
Cần có ủy quyền mới truy nhập được vào trang này. Bạn có thể thử đăng nhập hoặc thay đổi thư mục.
Cần có ủy quyền mới truy nhập được vào trang này. Bạn có thể thử thay đổi thư mục.
Applies to:
Databricks SQL preview
Databricks Runtime 11.3 LTS and above
Returns the date numDays after startDate. This function is a synonym for date_add (days) function.
Syntax
dateadd(startDate, numDays)
Arguments
startDate: A DATE expression.numDays: An INTEGER expression.
Returns
A DATE.
If numDays is negative abs(num_days) are subtracted from startDate.
If the result date overflows the date range the function raises an error.
To add units other than days use dateadd(unit, value, expr).
Examples
> SELECT dateadd('2016-07-30', 1);
2016-07-31