View a markdown version of this page

帳戶 - Amazon CloudWatch Logs

本文為英文版的機器翻譯版本,如內容有任何歧義或不一致之處,概以英文版為準。

帳戶

使用 accum命令來計算數值欄位的執行中累積總和。

語法

| accum field [AS out]

命令使用下列引數:

  • field – 要累積的數值欄位。

  • AS out (選用) – 輸出欄位的別名。

範例

下列查詢會計算執行中的位元組總數。

fields @timestamp, bytes | accum bytes AS totalBytes