https://supabase.com/ logo
#ideas-and-suggestions
Title
# ideas-and-suggestions
z

zernonia

07/29/2021, 12:54 PM
Hi, I created this https://supabase-schema.vercel.app/ to visualize Supabase schema easily. But visually creating and define relationship, then export as sql could be a great
enhancement
for this tools. 😍🔥
b

bdlukaa

07/29/2021, 3:33 PM
This is so good
Any way to export the schema?
g

Guaco

07/29/2021, 5:08 PM
This is neat!
z

zernonia

07/29/2021, 5:10 PM
Thank you for creating this thread.. this is new feature on Discord right? hahaha
g

Guaco

07/29/2021, 5:10 PM
Yes, thank you (:
z

zernonia

07/29/2021, 5:11 PM
Export the schema in what format ya? jpg/png?
b

bdlukaa

07/29/2021, 5:11 PM
I meant the sql schema
g

Guaco

07/29/2021, 5:11 PM
Export the code?
z

zernonia

07/29/2021, 5:13 PM
icic, not yet
g

Guaco

07/29/2021, 5:14 PM
You know what would be neat too? If you could let us create, edit, delete tables and like keep track of revisions
Eitherway, I really like and appreciate this. Thank you for creating it (:
b

bdlukaa

07/29/2021, 5:14 PM
hmm
I don't think it's possible with the current client libraries
g

Guaco

07/29/2021, 5:15 PM
Awh, how come? 😦
b

bdlukaa

07/29/2021, 5:15 PM
it's for security
z

zernonia

07/29/2021, 5:15 PM
exporting the sql schema meaning something like this?
Copy code
CREATE TABLE accounts (
    user_id serial PRIMARY KEY,
    username VARCHAR ( 50 ) UNIQUE NOT NULL,
    password VARCHAR ( 50 ) NOT NULL,
    email VARCHAR ( 255 ) UNIQUE NOT NULL,
    created_on TIMESTAMP NOT NULL,
        last_login TIMESTAMP 
);
Yup, due to security reason, the API for creating/editing table is not available (in public)
but.. the API is actually there, check out https://github.com/supabase/postgres-meta
b

bdlukaa

07/29/2021, 5:18 PM
like this one:
z

zernonia

07/29/2021, 5:19 PM
But what I had in mind is
user
can drag and drop creating/edit table, then it will generate either
create table or alter table
The part where creating table is possible, but not with RLS and function
due to current process of obtaining the database schema
i chose to use
url
and
anon
key because either way these info will be shown in
network
tab in Devtools, and Supabase encourage developer to enable RLS for security, so developer feels more
secured
in providing important information to an Open-Source product.
c

claud9

08/06/2021, 7:41 PM
@User , just wanted to say how useful your tool has been. Really awesome, so thank you!
z

zernonia

08/07/2021, 1:44 AM
Awesome! I updated it few hours ago, hope it will provides better experience ya