-- Create schema_version table if it doesn't exist
CREATE TABLE IF NOT EXISTS schema_version (
    version INTEGER PRIMARY KEY,
    script_name TEXT NOT NULL,
    applied_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP
);

-- Mark our first two migrations as applied
INSERT OR IGNORE INTO schema_version (version, script_name, applied_at) VALUES 
    (1, '001_init_schema.sql', datetime('now')); 