Filtering by last hour in select()

Hi there, I'm trying to use filters in the select with a boolean expression similar to the stories RLS example here: https://supabase.com/docs/guides/auth/row-level-security but it seems to be invalid? is this the wrong way to go about this?

I have a table called submissions in which I have a content field (arbitrary text) and created_at (now() timestamp) and I'm trying to match all submissions with the same content in the past hour (kind of a duplication check)

Here's how I've attempted to do it
    const { data } = await supabase
        .from("submissions")
        .select("content, created_at")
        .gt("created_at", "current_timestamp - interval '1 hour'")
        .eq("content", post);
Secure your data using Postgres Row Level Security.
Was this page helpful?