<?php

class Migration_20250218215827_alter_try_again_digit
{
    public static function up(PDO $pdo)
    {
        // Your migration code here
        $sql = "
            ALTER TABLE `call_histories` ADD COLUMN `try_again_code` VARCHAR(5) default 0 AFTER `pressed_digit`;
        ";
        $pdo->exec($sql);
    }

    public static function down(PDO $pdo)
    {
        // Rollback code here
        $query = "
            ALTER TABLE call_histories
            DROP COLUMN try_gain_code;
        ";

        $pdo->exec($query);
        echo "Column removed from `call_histories` table successfully.\n";
    }
}