Any thoughts on how to store users? I've got two user roles and I'm paralyzed about how to store their data. Should I put all users in one table or should I have a table for each role?
s
silentworks
11/12/2021, 2:50 PM
Like the stack exchange mentioned if the columns differ that much between both role types then different table could work, but personally I use 1 table and have a column to define the role
silentworks
11/12/2021, 2:50 PM
Also note that because Postgres supports json data (jsonb column type), you could store extra information in there which aren't related to both user types
t
Terry
11/12/2021, 3:09 PM
Thank you! I guess I'm reading that this is mostly personal preference — I hate personal preference 🙂 Far prefer rules!
s
silentworks
11/12/2021, 3:19 PM
Haha, almost everything in software is personal preference, rules are just a collectives personal preference 😆