Fellow #MastoAdmin people: if you need to track down all users invited by a particular user, here's an SQL query (disclosure: generated by Gemini, vetted and validated by me): see next post.
Here's users and the people who invited them, by date:
select u1.created_at, a1.username as sender, a2.username as recipient from users as u1 join invites on u1.invite_id = invites.id join users as u2 on invites.user_id = u2.id join accounts as a1 on u2.account_id = a1.id join accounts as a2 on u1.account_id = a2.id where u1.invite_id is not null order by u1.created_at;
Tekniquelly correct
in reply to Tim W RESISTS • • •Here's users and the people who invited them, by date:
select
u1.created_at,
a1.username as sender,
a2.username as recipient
from
users as u1
join invites on u1.invite_id = invites.id
join users as u2 on invites.user_id = u2.id
join accounts as a1 on u2.account_id = a1.id
join accounts as a2 on u1.account_id = a2.id
where
u1.invite_id is not null
order by
u1.created_at;
Edit: oops, forget a join