Nested ordering not working in V2

So it seems like I should be able to order by nested values on the supabase js sdk according to this:

https://github.com/supabase/supabase/discussions/229

q = this.sb.supabase.from('tags')
  .select('*, pid!inner(*, author!inner(*))', { count: 'exact' })
  .eq('name', tag)
  .order('pid.created_at', { ascending: true })
  .range(from, to)


tags
  • pid (fk to posts.id)
  • ...
posts
  • created_at
  • ...
I'm trying to sort by the posts created at field. I get a 400 error. However, when I comment out the .order() line, everything works fine.


J
GitHub
In an order expression is there a way to order the parent objects and the nested/foreign/child objects? Like this: supabase.from("parents").select(", children()&quo...
Was this page helpful?