ERROR: 42703: column "requester_id" does not exist
The database setup SQL had table creation order issues and column reference problems.
Go to your Supabase Dashboard:
- Open: https://supabase.com/dashboard/projects/hvjqvyozpczekwwizxzj
- Go to: Database → Tables
- Delete any existing tables manually if they exist:
photosmessageschat_roomsfriendshipslocationsusers
- Go to: SQL Editor in Supabase
- Copy the ENTIRE contents of the updated
database-setup.sql - Paste and Run - it will now work correctly!
- ✅ Proper table creation order (users first, then dependent tables)
- ✅ Correct foreign key references (all pointing to
public.users) - ✅ Clean slate setup (drops existing tables first)
- ✅ Better error handling for policies and triggers
After running the fixed SQL, you should see these tables created:
- ✅
users- User profiles and settings - ✅
locations- Real-time location data - ✅
friendships- Friend relationships - ✅
chat_rooms- Chat room metadata - ✅
messages- Chat messages - ✅
photos- Photo metadata
- Refresh your Expo Go app
- Try creating a new account
- Should work without errors now!
- Make sure you cleared all existing tables first
- Check that you copied the entire updated SQL file
- Look for any error messages in the SQL Editor
- Ensure your Supabase project is active
The database should now be properly set up for your Snapchat clone! 🎉