CREATE TABLE IF NOT EXISTS live_wallpaper (
    id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
    name VARCHAR(255) NOT NULL,
    description TEXT NOT NULL,
    wallpaper_url VARCHAR(1024) NOT NULL,
    thumbnail_video_url VARCHAR(1024) NOT NULL,
    price BIGINT UNSIGNED NOT NULL DEFAULT 0,
    created_time DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
    used_count BIGINT UNSIGNED NOT NULL DEFAULT 0,
    PRIMARY KEY (id),
    UNIQUE KEY uq_live_wallpaper_url (wallpaper_url(255)),
    KEY idx_live_wallpaper_created (created_time, id),
    KEY idx_live_wallpaper_used (used_count, id),
    KEY idx_live_wallpaper_name (name)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
