group by TB, gTP_TEID, gnb_id as GNB_ID
;
-DEFINE{ query_name 'distinct_users';
+DEFINE{ query_name 'requests_per_gtp_teid';
max_lfta_disorder '1'; max_hfta_disorder '1';
- comment 'Number of users based on distinct gTP_TEIDs seen';
+ comment 'Number of sgnb addition requests requests per gTP_TEID';
}
PARAM{ window uint;}
Select ($window*(tb+1))/1000 as TS, $window/1000.0 as measurementInterval,
- gnb_id as GNB_ID,
- count(*) as num_users
+ gnb_id as GNB_ID, gTP_TEID,
+ count(*) as n_requests
from SGNB_ADDITION_REQ.sgnb_addreq_gtp_teid
-group by timestamp_ms/$window as tb, gnb_id
+group by timestamp_ms/$window as tb, gnb_id, gTP_TEID
;
DEFINE{query_name 'gnb_ueid_teid_map';
sum(cnt) as n_handovers
from ho_count_events_gtp_teid
group by TB, GNB_ID, gTP_TEID
+;
+
+DEFINE{query_name 'gtp_teid_pci_join';
+ max_lfta_disorder '1'; max_hfta_disorder '1';
+ comment 'Join erab_stats_join with gnb_ueid_cellid_map to create data stream for requests_per_gtp_teid_cell';
+}
+PARAM{ window uint; }
+select M.TB, M.GNB_ID, M.physCellId, g.gTP_TEID
+INNER_JOIN from SGNB_ADDITION_REQ.sgnb_addreq_gtp_teid g, gnb_ueid_cellid_map M
+Where g.gnb_id=M.GNB_ID and g.id_MeNB_UE_X2AP_ID=M.id_MeNB_UE_X2AP_ID
+ and g.timestamp_ms/$window=M.TB
+;
+
+DEFINE{ query_name 'requests_per_gtp_teid_pci';
+ max_lfta_disorder '1'; max_hfta_disorder '1';
+ comment 'Number of sgnb addition requests requests per gTP_TEID';
+}
+PARAM{ window uint;}
+Select ($window*(TB+1))/1000 as TS, $window/1000.0 as measurementInterval,
+ GNB_ID, gTP_TEID, physCellId,
+ count(*) as n_requests
+from gtp_teid_pci_join
+group by TB, GNB_ID, gTP_TEID, physCellId
+