Private
Public Access
1
0

Fix column/card ordering: set COLLATE C on position columns

Postgres en_US.utf8 collation sorts case-insensitively, breaking the
lexicographic fractional indexing. Setting COLLATE "C" ensures pure
byte-order sorting. Applied via setup-collation.sql in entrypoint
after prisma db push.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Catherine Renelle
2026-02-26 07:40:13 -05:00
parent 8a97d354fa
commit 95f8e9a70b
2 changed files with 13 additions and 0 deletions
+7
View File
@@ -20,6 +20,13 @@ if [ $RETRY -ge $MAX_RETRIES ]; then
exit 1
fi
echo "Applying position column collation fix..."
if psql "$DATABASE_URL" -f ./scripts/setup-collation.sql; then
echo "Collation fix applied successfully."
else
echo "WARNING: Failed to apply collation fix. Continuing anyway..."
fi
echo "Applying RLS policies..."
if psql "$DATABASE_URL" -f ./scripts/setup-rls.sql; then
echo "RLS policies applied successfully."