Collectives

Stats

Top backers

SELECT max(c.name) as backer, concat('https://opencollective.com/',max(c.slug)) as "backer profile", 
  sum(t."amount")/ 100 as "totalAmount", max(t.currency) as currency
FROM "Transactions" t
LEFT JOIN "Collectives" c ON c.id = t."FromCollectiveId"
WHERE t."CollectiveId"=19965
  AND t.type='CREDIT'
  AND t."deletedAt" IS NULL
GROUP BY t."FromCollectiveId"
ORDER BY "totalAmount" DESC

Revenue breakdown per tier

SELECT max(t.name) as ticket, sum(o.quantity) as count,
  sum("totalAmount") / 100 as "totalAmount", max(o.currency) as currency
FROM "Orders" o
LEFT JOIN "Tiers" t ON t.id = o."TierId"
WHERE o."CollectiveId"=19965
  AND o.status='PAID'
  AND o."deletedAt" IS NULL
GROUP BY o."TierId"

Breakdown of expenses

List of backers with first and last donation

Number of donations and total donations per month per collective

Export

Export all backers of a collective with private data (user.email)

New collectives for the past XX and creator details

Expenses

Note: this export includes private data (user.email, expense.attachment)

Administration

Cancel all active subscriptions

Need to update CollectiveId (here 967) and deactivatedAt

Last updated