Skip to content

Instantly share code, notes, and snippets.

@Veejay
Created April 13, 2012 18:29
Show Gist options
  • Save Veejay/2378976 to your computer and use it in GitHub Desktop.
Save Veejay/2378976 to your computer and use it in GitHub Desktop.
SELECT
date(created_at) as ordered_date,
sum(price) as total_price
FROM
orders
GROUP BY
date(created_at)
HAVING
sum(price) > 100
@Veejay
Copy link
Author

Veejay commented Apr 13, 2012

Aye, even better cause less verbose.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment