1.CREATE TABLE feature.user_hot_click_list_weekly (
gid BIGINT NOT NULL,
feat_val TEXT NOT NULL,
create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
UNIQUE KEY (gid)
)
;
CREATE UNIQUE INDEX user_unique_gid ON feature.user_hot_click_list_weekly (gid);
CREATE INDEX user_hot_click_list_weekly_create_time_index
ON feature.user_hot_click_list_weekly (create_time)
;
set @gid=20892449;
MySQL [(none)]> select gid,feat_val,create_time
-> from feature.user_hot_click_list_weekly a
-> where gid = @gid \G
*************************** 1. row ***************************
gid: 20892449
feat_val: xxxxxx
create_time: 2020-06-14 18:31:10
1 row in set (3.97 sec)
MySQL [(none)]> select gid,feat_val,create_time
-> from feature.user_hot_click_list_weekly a
-> where gid = 20892449 \G
*************************** 1. row ***************************
gid: 20892449
feat_val: xxxxxxx
create_time: 2020-06-14 18:31:10
1 row in set (0.00 sec)