四半期セクションを作成したかったのですが、四半期ごとに特定の日付があるため、上限機能はありません。第1四半期は、10月22日から1月21日までです。だから私はこの関数を作成しました:(ロードスクリプト内)
if((Month(RetDate)='10' AND Day(RetDate)>21) OR (Month(RetDate) = '11' OR Month(RetDate) = '12') OR (Month(RetDate)='1' AND Day(RetDate)<22),'Q1',
if((Month(RetDate)='1' AND Day(RetDate)>21) OR (Month(RetDate) = '2' OR Month(RetDate) = '3') OR (Month(RetDate)='4' AND Day(RetDate)<22),'Q2',
if((Month(RetDate)='4' AND Day(RetDate)>21) OR (Month(RetDate) = '5' OR Month(RetDate) = '3') OR (Month(RetDate)='6' AND Day(RetDate)<22),'Q3','Q4'))) as Quarter1,
ただし、この方法では、たとえば、23.10.13 (10 月 23 日) は、2014 年の第 1 四半期ではなく、2013 年の第 1 四半期に関連付けられます。
ありがとう :)