Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- month in the last year had the highest average IACV for closed won deals?
- SELECT
- date_trunc('month', close_date)::date AS month,
- AVG(weighted_iacv) AS iacv
- FROM sdfc_opportunity_xf
- WHERE (is_closed AND is_won AND close_date BETWEEN '2018-08-14' and '2019-08-14')
- GROUP BY month
- ORDER BY iavc
- LIMIT 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement