public function getLastBatchNumber(): int
    {
        $stmt = $this->pdo->query("select max(batch) from {$this->table}");
        $stmt->execute();

        return (int) $stmt->fetch(PDO::FETCH_ASSOC)['max'];
    }