Learn

Great! That query doesn’t take refunds into account. We’ll update the query to exclude refunds.

Fields like refunded_at will only have data if the transaction was refunded, and otherwise left null.

Instructions

1.

Update our daily revenue query to exclude refunds.

Complete the query by filtering for refunded_at is null.

select date(created_at), round(sum(price), 2) as daily_rev from purchases where /**/ group by 1 order by 1;
Folder Icon

Sign up to start coding

By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.

Already have an account?