-- Initialize database with proper settings
SET SQL_MODE = '';

-- Create database if not exists
CREATE DATABASE IF NOT EXISTS tg_manage CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;

USE tg_manage;

-- Grant privileges to user
GRANT ALL PRIVILEGES ON tg_manage.* TO 'tg_manage'@'%';
FLUSH PRIVILEGES;