Skip to content

AZ621: Which table holds the users? ​

The draft's user type is the table that holds your users. rowstile init takes the first table named like one (users, user, accounts, account, people, persons, profiles), else the table that most columns named like user_id, owner_id, author_id or creator_id point to. Here it found none, or the table those columns point to can't be drafted: it is in a schema the draft doesn't read (as Supabase's auth.users, with --schema public), or the draft leaves it out (a name the policy language can't write, no primary key; the message says which). Draft that schema too (--schema public,auth), or name the table: rowstile init --users public.profiles. --users takes a table with a primary key, in a schema the draft reads.

Reported by the command, against a database.