Help me with this query with variables

  • Goal: Populate a table using a query from a Supabase database. I'm trying to return data based on a variable currentYear.
  • Steps: When the user clicks on 2012 in the navigation bar, I've got it setup to define the currentYear variable as 2012. But the query returns the error in the screenshot.
  • Details: If I modify the query and have it be '2012' instead of '{{ currentYear }}', the query returns the correct data. There's an error somehow with how the variable is being defined/passed/etc.
  • Screenshots:

Cross posting the response: Help me fix this query uzi - #3 by pyrrho