How do I know if a database is being queried?

Hi All
I need some assistance with removing a data source connected to Metabase.
We're currently pointing our heap analytics data into metabase but we're currently reviewing all our projects within heap and are wanting to remove these unused/outdated data sources.

Is there a way to view/check if a particular database is being called for a query within Metabase? We want to make sure that no existing reports/queries will break after removing a datasource.

A not so efficient method would be to trawl through all of the queries ever made manually to see if it references that database but surely there's a better way?

If your Metabase internal DB is MySQL then you can use this query

Thanks for sharing that!

I also managed to find another method in this article! Finding queries that utilize a specific table