--按年获取
select generated_period_start from SERIES_GENERATE_DATE('interval 1 year' , current_date ,add_years(current_date , 3)) ;
--按月获取
select generated_period_start from SERIES_GENERATE_DATE('interval 1 month' , current_date ,add_years(current_date , 3)) ;
--按天获取
select generated_period_start from SERIES_GENERATE_DATE('interval 1 day' , current_date ,add_years(current_date , 3)) ;
HANA SQL FUNCTION -获取日期相关序列
于 2024-06-18 10:21:18 首次发布