@golemio/rush-hour-aggregation 1.1.8-dev.1048813765 → 1.1.8-dev.1051584167

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@golemio/rush-hour-aggregation",
3
- "version": "1.1.8-dev.1048813765",
3
+ "version": "1.1.8-dev.1051584167",
4
4
  "description": "Rush hour data aggregation for Praha dopravní project",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -22,12 +22,12 @@ from (
22
22
  select distinct
23
23
  tsk_std.latitude,
24
24
  tsk_std.longitude,
25
- ((tsk_std.street::text || '('::text) || tsk_std.segment::text) || ')'::text as lokace,
26
- st_setsrid(st_makepoint(tsk_std.longitude, tsk_std.latitude), 4326) as geom
25
+ ((archive.tsk_std.street::text || '('::text) || archive.tsk_std.segment::text) || ')'::text as lokace,
26
+ st_setsrid(st_makepoint(archive.tsk_std.longitude, archive.tsk_std.latitude), 4326) as geom
27
27
  from
28
- tsk_std
28
+ archive.tsk_std
29
29
  where
30
- tsk_std.latitude is not null and tsk_std.longitude is not null
30
+ tsk_std.latitude is not null and archive.tsk_std.longitude is not null
31
31
  ),
32
32
  sdata as (
33
33
  select
@@ -40,7 +40,7 @@ from (
40
40
  mes.value
41
41
  from
42
42
  kalendar kalendar_1
43
- cross join tsk_std
43
+ cross join archive.tsk_std
44
44
  left join (
45
45
  select
46
46
  measured_from,
@@ -49,17 +49,17 @@ from (
49
49
  class_id,
50
50
  measurement_type,
51
51
  value
52
- from tsk_std_measurements
52
+ from archive.tsk_std_measurements
53
53
  where
54
54
  measured_from >= (date_part('epoch'::text, (timestamp with time zone :from))::bigint * 1000)
55
55
  and measured_to <= (date_part('epoch'::text, (timestamp with time zone :to))::bigint * 1000)
56
56
  ) mes on
57
57
  (date_part('epoch'::text, kalendar_1.a)::bigint * 1000) >= mes.measured_from
58
58
  and (date_part('epoch'::text, kalendar_1.a)::bigint * 1000) <= mes.measured_to
59
- and tsk_std.id::text = mes.detector_id::text
59
+ and archive.tsk_std.id::text = mes.detector_id::text
60
60
  where
61
- tsk_std.latitude is not null
62
- and tsk_std.longitude is not null
61
+ archive.tsk_std.latitude is not null
62
+ and archive.tsk_std.longitude is not null
63
63
  ) select
64
64
  date_part('epoch'::text, kalendar.a::timestamp without time zone) * 1000::double precision as measured_at,
65
65
  ciselnik.geom,
@@ -85,7 +85,7 @@ from (
85
85
  and ciselnik.longitude = sdata.longitude
86
86
  and kalendar.a = sdata.time_5min
87
87
  and sdata.value is not null
88
- left join tsk_std_class_types cls on
88
+ left join archive.tsk_std_class_types cls on
89
89
  cls.id = sdata.class_id
90
90
  group by
91
91
  ciselnik.latitude,