ALTER TABLE static_function ADD COLUMN IF NOT EXISTS stack_frame TEXT;
ALTER TABLE static_function ADD COLUMN IF NOT EXISTS comments TEXT;

CREATE TABLE IF NOT EXISTS static_import
(
    id            UUID PRIMARY KEY,
    analysis_id   UUID         NOT NULL REFERENCES static_analysis (id) ON DELETE CASCADE,
    dll           VARCHAR(255) NOT NULL,
    name          VARCHAR(500) NOT NULL,
    address       VARCHAR(20),
    ordinal       INTEGER      NOT NULL DEFAULT 0
);

CREATE INDEX IF NOT EXISTS idx_static_import_analysis_id ON static_import (analysis_id);
