Filters & use of table aliases

Welcome @Akii1997.

In the Metabase Documentation under SQL Parameters there's a really good explanation of how to formulate variables for filters. A couple of tricks that may not be so clear and lots of users had to learn the hard way that may save you some time:

  1. create a view of what you've already done and use it instead, that way the entire table referencing issue is gone, Metabase works best with a single table or view,
  2. don't use table aliases (you don't appear to here which is good), Metabase doesn't support them,
  3. start off every WHERE statement with WHERE 1=1 or some innocuous required statement like it, followed by your AND this, that, or the other kind of statement you're defining (no idea why, it just works, just do it)

One other option in your case is the following post but you'd have to follow-up with the author because I can't quite make out what his solution means by "put everything between double quotes", I've never been able to make it work!

Another thing is Metabase has a GitHub site where you can sign-in and explore various technical issues users are having and propose solutions -- it's not for asking general how-to type questions, that's what this forum is for. But you can gain allot of insight there, participate in the discussions, propose solutions, request enhancements, etc. For example, I'm particularly interested in Limit the number of options displayed in a filter based on the selection of another filter. #5540 and so I encourage everyone who inquires about something like this on this forum (and there are ALLOT of users who ask for this one!) to go there and "Upvote" :+1: the first post for that issue -- the Metabase team uses these as a guide to what features users need help with and enhancements they need.

Hope this helps!