zhibo/add_view_history_121.sql

19 lines
1.2 KiB
SQL
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- =====================================================
-- 为用户"道玄"ID: 121添加观看历史到 eb_view_history 表
-- =====================================================
-- 插入观看历史数据
INSERT INTO eb_view_history (user_id, target_type, target_id, target_title, view_duration, create_time, update_time) VALUES
(121, 'room', '1', '欢乐游戏直播', 1800, '2026-01-03 20:30:00', '2026-01-03 20:30:00'),
(121, 'room', '2', '音乐分享会', 2400, '2026-01-03 21:00:00', '2026-01-03 21:00:00'),
(121, 'room', '3', '户外探险直播', 900, '2026-01-02 19:00:00', '2026-01-02 19:00:00'),
(121, 'room', '4', '美食制作教程', 3600, '2026-01-02 12:00:00', '2026-01-02 12:00:00'),
(121, 'room', '5', '编程技术分享', 5400, '2026-01-01 14:00:00', '2026-01-01 14:00:00'),
(121, 'work', '1', '搞笑短视频合集', 180, '2026-01-03 22:00:00', '2026-01-03 22:00:00'),
(121, 'work', '2', '旅行Vlog-云南之旅', 600, '2026-01-03 18:00:00', '2026-01-03 18:00:00'),
(121, 'work', '3', '美妆教程分享', 420, '2026-01-02 16:00:00', '2026-01-02 16:00:00');
-- 验证数据
SELECT COUNT(*) as FROM eb_view_history WHERE user_id = 121;
SELECT * FROM eb_view_history WHERE user_id = 121 ORDER BY update_time DESC;