Created
May 15, 2017 12:28
-
-
Save carols10cents/48e495198f329e52f74978c59b094581 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select count(distinct crate_owners.owner_id) | |
from crates | |
join crate_owners | |
on crates.id = crate_owners.crate_id | |
where date(crates.created_at) >= '2016-05-15' | |
and crate_owners.owner_id NOT IN ( | |
select distinct crate_owners.owner_id | |
from crates | |
join crate_owners | |
on crates.id = crate_owners.crate_id | |
where date(crates.created_at) < '2016-05-15' | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment