Slow query

Hello, i have an issue and i'm seeking for help.

We are runing metabase on postgres and java.
I have a querry that runs 15 seconds in Postgres enviroment.

I post it in Metabase using SQL querry interface and it takes around 20 seconds to execute it.
But when i try to save results to do some filters and dashboards on over my table - it takes more then 10 minutes to execute it.

I can find anything relevant in logs.
any hints?

I would look at the filters being used in Metabase and make sure that there are corresponding indexes in your Postgres table(s). It may be that the initial query is OK, but when you add the filters, the query engine is having to do a table scan to get the results.