Index: trunk/fundraiser-statistics/fundraiser-scripts/sql/report_LP_confidence.sql |
— | — | @@ -20,13 +20,13 @@ |
21 | 21 | landing_page, |
22 | 22 | utm_campaign, |
23 | 23 | count(*) as views |
24 | | -from landing_page |
| 24 | +from landing_page_requests |
25 | 25 | where request_time >= '%s' and request_time < '%s' |
26 | 26 | and utm_campaign REGEXP '%s' |
27 | 27 | and landing_page REGEXP '%s' |
28 | 28 | group by 1,2) as lp |
29 | 29 | |
30 | | -join |
| 30 | +left join |
31 | 31 | |
32 | 32 | (select |
33 | 33 | SUBSTRING_index(substring_index(utm_source, '.', 2),'.',-1) as landing_page, |
Index: trunk/fundraiser-statistics/fundraiser-scripts/sql/report_banner_confidence.sql |
— | — | @@ -25,7 +25,7 @@ |
26 | 26 | (select |
27 | 27 | utm_source, |
28 | 28 | sum(counts) as impressions |
29 | | -from impression |
| 29 | +from banner_impressions |
30 | 30 | where on_minute > '%s' and on_minute < '%s' |
31 | 31 | and utm_source REGEXP '%s' |
32 | 32 | group by 1) as imp |
— | — | @@ -35,7 +35,7 @@ |
36 | 36 | (select |
37 | 37 | utm_source, |
38 | 38 | count(*) as views |
39 | | -from landing_page |
| 39 | +from landing_page_requests |
40 | 40 | where request_time >= '%s' and request_time < '%s' |
41 | 41 | and utm_campaign REGEXP '%s' |
42 | 42 | group by 1) as lp |
— | — | @@ -47,14 +47,14 @@ |
48 | 48 | (select |
49 | 49 | utm_source, |
50 | 50 | count(*) as total_views |
51 | | -from landing_page |
| 51 | +from landing_page_requests |
52 | 52 | where request_time >= '%s' and request_time < '%s' |
53 | 53 | and utm_source REGEXP '%s' |
54 | 54 | group by 1) as lp_tot |
55 | 55 | |
56 | 56 | on imp.utm_source = lp_tot.utm_source |
57 | 57 | |
58 | | -join |
| 58 | +left join |
59 | 59 | |
60 | 60 | (select |
61 | 61 | SUBSTRING_index(substring_index(utm_source, '.', 2),'.',1) as banner, |