src: |
  SELECT p_indicateurs_cumules.date_reference AS jour_now,
      date(date_trunc('month'::text, p_indicateurs_cumules.date_reference::timestamp with time zone) + '1 mon'::interval - '1 day'::interval) AS mois_now,
      date(date_trunc('year'::text, p_indicateurs_cumules.date_reference::timestamp with time zone) + '1 year'::interval - '1 day'::interval) AS annee_now
     FROM pmsi.p_indicateurs_cumules
    WHERE p_indicateurs_cumules.periode_type = 'NOW'::text;