Filter on "Countif" Summarized Question

Hi, i have one table (Atendimentos) to save the tickets opened from clients with a column to reference the opening date (Data de Abertura) and a relationship with another table (Clientes) to reference the client who opened the ticket.

I need an alert when a client (from Clientes) have one new ticket opened in the last hour AND one or more tickets opened in the last 30 days.

I solved this with: A filter to opening date (Data de Abertura) in previous 30 days; And a summarized with “Count” and another summarized named “Last Hour” with “CountIf(interval([Data de Abertura], -1, “hour”))”.

The results are ok, but i can’t filter just the clients with more than 0 in summarize “Last Hour”.
Above are de screenshots from the question.

PS: If any have another idea to solve the question, i’ll appreciate.

Experiencing roughly the same issue MBQL - perhaps as a grammar or maybe the execution engine - isn’t flushed out enough to treat calculated and aggregate columns the same way as a normal column reference, things fall further apart with joins and referencing fields on the left side of the join for filtering. MongoQL can handle this (should be able to model in clojure’s EDN). I think this is deep underlying limitation of the platform that the underling query grammar (syntax?parsing?) isn’t robust enough to model everyday questions from stakeholders (including example that almost canonical in ecommerce) - we’re at about 95% bounce-to-developer to handle it with bigquery views with stakeholders at the moment (you see my previous thread of roughly similar example).

MBQL needs a deep rethink - hammock time as Rich Hickey would say.

Hi @yuriandreoli
Click the Filter button in the bottom to insert a new Filter-section, which can filter the aggregated data (Summarize-section).

@mat93393 I really don’t see what you comment has to do with this question, nor what the GUI has to do with MBQL. It would better suited for it’s own topic.

Thanks @flamber, but I already did that and didn’t work.

If I filter the “Count” works perfectly, but when I filter the “Last Hour” I receive the error: “Unknown column ‘source.Last Hour’ in ‘where clause’”

@yuriandreoli Okay, I have created an issue for it - even though I think it might be a duplicate of another issue: - upvote by clicking :+1: on the first post

Thanks @flamber, I’ll wait the update to solve the problem.