Important: For assistance on SQL variables and a fields reference guide, please
click the Help link.
CREATE TABLE $FINAL_RESULT_TABLE
SELECT DISTINCT -- prevents duplicate rows (that is, overlapping permissions)
ts.name
, ts.contact
, ts.bytes_transferred
, ts.bytes_lost
, TRUNCATE((ts.bytes_lost)*100/(ts.bytes_transferred + ts.bytes_lost), 1) AS `packet loss %`
, ts.source_ip AS `from`
, ts.dest_ip AS `to`
, ts.started_at
, ts.stopped_at
, ts.status
, ts.files_complete
, ts.files_failed
, ts.files_skipped
FROM
$TBL_TRANSFER_SESSIONS ts
WHERE
((ts.bytes_lost * 100) /(ts.bytes_lost + ts.bytes_transferred)) >= $PACKET_LOSS /* Custom/configurable variable */
AND
ts.started_at < '$REPORT_PERIOD_END'
AND (
ts.stopped_at >= '$REPORT_PERIOD_START'
OR ts.stopped_at IS NULL
)
ORDER BY
5 DESC
, 8
;
Important: For demonstration purposes, we have created a configurable/custom
variable called $PACKET_LOSS in the SQL script text above. You may,
alternatively, utilize the built-in SQL database field avg_loss_pct,
to display the average packet loss over the network (as a percentage).
Please see the Help link in the application for details.