Pgsql 获取当前周/季度 的开始和结束时间
select date_trunc('week', current_date::timestamp) as 周开始时间;
select date_trunc('week',current_date::timestamp) + '6 days' as 周结束时间;
select date_trunc('quarter', current_date::timestamp) as 季度开始时间;
select date_trunc('quarter', current_date::timestamp) + '3 month' - interval '1 d' as 季度结束时间;