-- CreateTable
CREATE TABLE `AccountBalance` (
    `id` INTEGER NOT NULL AUTO_INCREMENT COMMENT 'Primary key for account balance entries.',
    `balanceValue` DECIMAL(14, 2) NOT NULL COMMENT 'Balance amount captured at the timestamp.',
    `currency` VARCHAR(10) NOT NULL COMMENT 'Currency code for the balance (e.g., HUF, EUR).',
    `companyName` VARCHAR(100) NOT NULL COMMENT 'Company name that owns the account balance (Prompt-H or ITStudy).',
    `balanceDate` DATETIME(0) NOT NULL COMMENT 'Date and time when the balance was recorded.',
    `comment` TEXT NOT NULL COMMENT 'Free-form comment or memo for the entry.',

    PRIMARY KEY (`id`)
) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;

-- CreateIndex
CREATE INDEX `account_balance_company_date` ON `AccountBalance`(`companyName`, `balanceDate`);
