ยฉ 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabaseโ€ข5mo agoโ€ข
2 replies
Ben H

trouble setting up declarative schema

i'm testing setting up a declarative schema.

i created a brand new supabase project.

created new, empty local repo and linked to the project.

did
supabase db pull
supabase db pull
to sync with the remote project.

then did
supabase db dump --schema public > supabase/schemas/$(date +%Y%m%d%H%M%S)_remote_schema.sql
supabase db dump --schema public > supabase/schemas/$(date +%Y%m%d%H%M%S)_remote_schema.sql
to start setting up my schema.

however, both the dump and the migration files include content like this:

\restrict cqc0H9DqzJcF9rVGRWAxMVqRNXwqyXFScoC9gC3tzKAkymcpw220JFgV3CHCCf5
\restrict cqc0H9DqzJcF9rVGRWAxMVqRNXwqyXFScoC9gC3tzKAkymcpw220JFgV3CHCCf5


which results in an error when running supabase db diff:

Applying migration 20250912181907_remote_schema.sql...
ERROR: syntax error at or near "\" (SQLSTATE 42601)                      
At statement: 0                                                          
\restrict cqc0H9DqzJcF9rVGRWAxMVqRNXwqyXFScoC9gC3tzKAkymcpw220JFgV3CHCCf5
^                   
Applying migration 20250912181907_remote_schema.sql...
ERROR: syntax error at or near "\" (SQLSTATE 42601)                      
At statement: 0                                                          
\restrict cqc0H9DqzJcF9rVGRWAxMVqRNXwqyXFScoC9gC3tzKAkymcpw220JFgV3CHCCf5
^                   


is this expected behavior? why isn't this working?
Supabase banner
SupabaseJoin
Supabase gives you the tools, documentation, and community that makes managing databases, authentication, and backend infrastructure a lot less overwhelming.
45,816Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Declarative schema and MCP
SupabaseSSupabase / help-and-questions
2mo ago
Declarative database schemas
SupabaseSSupabase / help-and-questions
3w ago
Trouble setting up Login with GitHub
SupabaseSSupabase / help-and-questions
4y ago
Trouble setting up MCP integration in Cursor
SupabaseSSupabase / help-and-questions
7mo ago