Postgres db update

I upgraded my postgres to 17 and after the upgrade all the relations aren’t working anymore… someone knows what can I do in order to return them and not manually adding them again?
2 Replies
silentworks
silentworks1h ago
Not sure what this mean as the upgrade shouldn't affect your table schema nor your data at all. Can you provide an concrete example of what was working before that is not working now? since you tagged PostgREST in this post it would be good if you showed a code example of what is not working.
ykandel
ykandelOP1h ago
Issue: After applying a security migration that modified 90+ database functions (setting search_path to prevent injection attacks), PostgREST started returning 404 errors for existing tables. What was working → stopped working: 1. Private Messages API:
POST /rest/v1/private_messages?select=*
→ 404 (Not Found)
Error: relation "message_read_receipts" does not exist
POST /rest/v1/private_messages?select=*
→ 404 (Not Found)
Error: relation "message_read_receipts" does not exist
2. RPC Function Calls:
supabase.rpc('check_user_can_send_message', { ... })
Error: function check_user_can_send_message(uuid, text, text) does not exist
supabase.rpc('check_user_can_send_message', { ... })
Error: function check_user_can_send_message(uuid, text, text) does not exist
3. Course Enrollment:
POST /rest/v1/course_enrollments
→ Error: relation "courses" does not exist
POST /rest/v1/course_enrollments
→ Error: relation "courses" does not exist
Database State: - ✅ All tables exist in public schema - ✅ All permissions granted to anon and authenticated roles - ✅ All functions exist with correct signatures - ✅ RLS policies are active and correct tried reloading the scheme- didn't work... many times, 2 hours already.

Did you find this page helpful?