JavaScript: Using explain

Return data as the EXPLAIN plan for the query.

You need to enable the db_plan_enabled setting before using this method.

Parameters

Examples

Get the execution plan

const { data, error } = await supabase
  .from('characters')
  .select()
  .explain()

Get the execution plan with analyze and verbose

const { data, error } = await supabase
  .from('characters')
  .select()
  .explain({analyze:true,verbose:true})