共用方式為


批次

查詢可以包含多個表格式運算式陳述式,只要其是以分號 (;) 字元分隔。 然後查詢會傳回多個表格式結果。 結果是由表格式運算式陳述式所產生,並根據查詢文字中的陳述式順序進行排序。

注意

範例

名稱表格式結果

下列查詢會產生兩個表格式結果。 然後,使用者代理程式工具可以顯示這些結果,以及與每項相關聯的適當名稱 (分別為 Count of events in FloridaCount of events in Guam)。

StormEvents | where State == "FLORIDA" | count | as ['Count of events in Florida'];
StormEvents | where State == "GUAM" | count | as ['Count of events in Guam']

共用計算

批次處理適用於一般計算會由多個子查詢共用的案例 (例如儀表板)。 如果一般計算很複雜,請使用 materialize() 函式,並建構查詢,使得其只會執行一次:

let m = materialize(StormEvents | summarize n=count() by State);
m | where n > 2000;
m | where n < 10