I have the following Activity
table:
ID TYPE SKU
=======================
1 create ABC
2 create DEF
3 destroy DEF
How can I get all create
events which DON'T have a destroy
event?
Doing Activity.where(type: 'create')
gives me ids 1 and 2.
But I only want the first row since id 2 also has a destroy event.