How to order both the Supabase parent (claims table) and referenced (approval_logs table) tables?
Hi @jwkhor
I don’t think you can sort by both columns there, only one. Have you tried using the Call a Postgres function action or sorting at the collection level?
another option is to use some custom js and use the supabase docs to help you out
the supabase instance in weweb is
wwLib.wwPlugins.supabase.instance
Hi @sam1
Yes, thanks, that also but, personally, I think it’s more of a hack than a native WeWeb solution. WeWeb is no-code, so avoiding custom code as much as possible is good practice. It’s hard for us to provide support when people’s projects have a lot of custom code and many things can go wrong in custom code as well, especially after we release updates.
Maybe that’s an input to improve, instead of blocking people and offloading the problem to Supabase. How is this any more no-code?
@Broberto We are trying to improve all the time, but we don’t encourage hacks. Custom JS needs to be avoided - too much is bad practice.
Thanks for the suggestion!
I did consider sorting at the collection level, but cannot sort it.
then I tried using the ‘Call a Postgres function’ method, and it worked.
thank you
However, writing in PostgreSQL is a bit challenging.
Nice @jwkhor, I will suggest to the team that we add the feature to the Select action as soon as possible.