• Stefy Lanza (nextime / spora )'s avatar
    Fix SQL reset script to respect foreign key constraints · 6a5e8b04
    Stefy Lanza (nextime / spora ) authored
    - Fix deletion order: child tables before parent tables
    - Add bet_details deletion before bets deletion
    - All 4 options updated with correct deletion order
    - Prevents foreign key constraint errors
    
    Deletion order:
    1. report_sync_logs (no dependencies)
    2. match_reports (child of report_syncs)
    3. extraction_stats (child of report_syncs)
    4. bet_details (child of bets)
    5. bets (parent of bet_details, child of report_syncs)
    6. report_syncs (parent of bets, extraction_stats, match_reports)
    6a5e8b04