More tricky question, how can I activate realtime ...
# off-topic
p
More tricky question, how can I activate realtime outside of supabase UI ? I've tried
alter publication supabase_realtime add table table_test;
from a node client or by wrapping it in an RPC but I always get:
must be owner of publication supabase_realtime
s
What's the use case for this? as in why would you have it turn on from outside of the UI?
p
If I want a user to create a table and activate the realtime on this new table for example.
I can activate realtime on ALL tables so that's an option but then I'll have it also on table I don't need to
So it would not be a toggling feature but really the ability to activate it on some table from a node client (or else)
s
Wait why would a user be creating a table? that should be handled by the person managing the system. I've seen this approach by others due to having NoSQL backgrounds, do note that relational database doesn't work this way and shouldn't be used in this way
p
why not ? Let's say I want to build something like Airtable. I'd like - in some restricted server-side scripts - to create table on demand.
Sure it won't scale and I'll have issue at some point but that's doesn't seems so strange
s
You would build that on a NoSQL database or use a
jsonb
column to handle something like that, that is not a good use case for a relational database. Or you would design your table schemas in a better way for relational database.
You don't create tables on a fly with relational databases
p
Ok, I'd be curious to understand the red flag here ? I'll look into your solutions 🙂 thx !