Migration:Documentation Index
Fetch the complete documentation index at: https://docs.encoreos.io/llms.txt
Use this file to discover all available pages before exploring further.
20260121000000_performance_indexes_phase2.sqlDate: 2026-01-21
Status: Production ✅ | Staging ✅ COMPLETE
Deployment Summary
Production ✅ COMPLETE
- Status: ✅ Successfully deployed via MCP
- Date: 2026-01-21
- Indexes Created: 13 indexes (4 date range, 3 multi-column, 5 sort, 1 search)
Staging ✅ COMPLETE
- Project ID:
bcuftbeczbudndukafbc - Status: ✅ Successfully deployed via CLI
- Date: 2026-01-21
- Indexes Created: 13 indexes (4 date range, 3 multi-column, 5 sort, 1 search)
Deploy to Staging
Option 1: Using Supabase CLI (Recommended)
Option 2: Using Supabase Dashboard
- Navigate to: Supabase project dashboard
- Go to: SQL Editor
- Copy and paste the SQL from:
supabase/migrations/20260121000000_performance_indexes_phase2.sql - Execute the SQL
- Verify indexes were created
Option 3: Using Migration Apply Tool
If you have access to staging MCP connection:Verification Queries
After deploying to staging, run these queries to verify:Indexes Created
Date Range Queries (4 indexes)
idx_rh_schedule_instances_org_dateidx_rh_attendance_records_org_scheduleidx_hr_leave_requests_org_start_dateidx_gr_audits_org_scheduled_date
Multi-Column Filters (3 indexes - conditional)
idx_it_tickets_org_site_status(if site_id exists)idx_rh_episodes_org_site_status(if site_id exists)idx_fm_work_orders_org_site_status(if site_id exists)
Sort Optimization (5 indexes)
idx_gr_audits_org_created_descidx_it_tickets_org_created_descidx_hr_leave_requests_org_created_descidx_rh_episodes_org_created_descidx_fm_work_orders_org_created_desc
Search Optimization (1 index)
idx_it_tickets_org_subject
Configuration Updated
✅ config.toml updated with correct staging project ID:bcuftbeczbudndukafbc
Next Steps
- Deploy to Staging using one of the methods above
- Verify indexes using the verification query
- Monitor performance after 1 week
- Check index usage to ensure indexes are being utilized
Last Updated: 2026-01-21