I can get the badge id for a specific user, for example query:
Select *
From Badges
Where UserId = 10907521
Example badge id from result
30884218
But, how is it possible to get the associated question or answer id (if applicable) for every badge awarded to a user?
For those badges which are not related to a Q&A, we could expect an "NA".