-- Create missing kso_id_sequence table for auto-incrementing KSO IDs
CREATE TABLE IF NOT EXISTS `kso_id_sequence` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `created_at` timestamp DEFAULT current_timestamp(),
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- Insert some initial values if table is empty
INSERT IGNORE INTO kso_id_sequence (id) VALUES 
(1), (2), (3), (4), (5), (6), (7), (8), (9), (10);
