JavaScript: filter

Match only rows which satisfy the filter. This is an escape hatch - you should use the specific filter methods wherever possible.

Unlike most filters, opearator and value are used as-is and need to follow PostgREST syntax. You also need to make sure they are properly sanitized.

Parameters

Examples

With `select()`

const { data, error } = await supabase
  .from('characters')
  .select()
  .filter('name', 'in', '("Han","Yoda")')

On a referenced table

const { data, error } = await supabase
  .from('orchestral_sections')
  .select(`
    name,
    instruments!inner (
      name
    )
  `)
  .filter('instruments.name', 'eq', 'flute')