-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtables.sql
More file actions
51 lines (49 loc) · 1.61 KB
/
Copy pathtables.sql
File metadata and controls
51 lines (49 loc) · 1.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
USE bidding;
CREATE TABLE `tracking_clicks`
(
`created_at` timestamp,
`create_id` int(11) NOT NULL,
`campaign` int(11) NOT NULL,
`app_id` int(11) NOT NULL,
`ad_set_id` int(11) NOT NULL,
`ch_id` int(11) NOT NULL,
`user_id` int(11) NOT NULL,
`offer_id` int(11) NOT NULL,
`creative_id` int(11) NOT NULL,
`click_id` int(11) NOT NULL,
PRIMARY KEY (`click_id`)
);
CREATE TABLE `tracking_impressions`
(
`created_at` timestamp,
`create_id` int(11) NOT NULL,
`campaign` int(11) NOT NULL,
`app_id` int(11) NOT NULL,
`ad_set_id` int(11) NOT NULL,
`ch_id` int(11) NOT NULL,
`user_id` int(11) NOT NULL,
`offer_id` int(11) NOT NULL,
`creative_id` int(11) NOT NULL,
`impression_id` int(11) NOT NULL,
PRIMARY KEY (`impression_id`)
);
CREATE TABLE `events`
(
`event_time` DATETIME NOT NULL,
`event_time_ts` bigint(20) NOT NULL,
`request_id` varchar(50) DEFAULT NULL,
`placement_id` varchar(50) DEFAULT NULL,
`app_id` varchar(50) NOT NULL,
`ad_set_id` varchar(50) NOT NULL,
`ch_id` varchar(50) NOT NULL,
`user_id` varchar(50) NOT NULL,
`offer_id` varchar(50) NOT NULL,
`creative_id` varchar(50) NOT NULL,
`event_id` varchar(50) NOT NULL,
`event_type` varchar(50) NOT NULL,
`geo` varchar(10) DEFAULT NULL,
`device` varchar(50) DEFAULT NULL,
`os_version` varchar(50) DEFAULT NULL,
`device_ip` varchar(50) DEFAULT NULL,
`ua` text CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL
);