3
Seeding Data
Source: supabase/supabase#19773 · opened by @whymlaszlo
Hello all,
The current situation is that you have to write a seed script if you want to have seeding data in the database. This is then located here: ./supabase/seed.sql
However, the script can quickly become quite large and confusing.
Is it perhaps possible to define a location, e.g. ./supabase/seed/, where all .sql files are then read in and processed in sequence? This would make it possible to write a script 01_users.sql, which first writes the users to the database and then reads a 02_orders.sql and writes orders to the database. This may be much more structured.
What do you think? Or is there already a similar functionality?
Thanks.
The current situation is that you have to write a seed script if you want to have seeding data in the database. This is then located here: ./supabase/seed.sql
However, the script can quickly become quite large and confusing.
Is it perhaps possible to define a location, e.g. ./supabase/seed/, where all .sql files are then read in and processed in sequence? This would make it possible to write a script 01_users.sql, which first writes the users to the database and then reads a 02_orders.sql and writes orders to the database. This may be much more structured.
What do you think? Or is there already a similar functionality?
Thanks.
No pledges yet. Be the first to back this.
Comments
Similar requests
Export SQL statements in Table Editor
9 votes · 0 comments
Feture Request: Want to get some part of data encrypted via RSA Private keys to avoid client side data manipulation
1 vote · 0 comments
Authenticated API Endpoint to Restart / Toggle Database On & Off Remotely
2 votes · 0 comments
How to synchronize databases, documents to vector databases
3 votes · 0 comments
Add autoRefresh Option to getUser() to Ensure Session Data is Synced with Latest User State
3 votes · 0 comments
No comments yet.