<?php
require_once 'config/database.php';

try {
    echo "Testing classes table...\n";
    $result = $pdo->query('SELECT COUNT(*) FROM classes');
    echo "Classes count: " . $result->fetchColumn() . "\n";
    
    echo "Testing columns...\n";
    $columns = $pdo->query('DESCRIBE classes')->fetchAll();
    foreach ($columns as $col) {
        echo "- " . $col['Field'] . " (" . $col['Type'] . ")\n";
    }
    
    echo "SUCCESS: Classes system is ready!\n";
} catch (Exception $e) {
    echo "ERROR: " . $e->getMessage() . "\n";
}
?>