次の方法で共有


fork 演算子

複数のコンシューマー演算子を並列実行します。

構文

T | fork [name=]](subquery) [name=](subquery) ...

構文規則について詳しく知る。

パラメーター

件名 タイプ Required 説明
subquery string ✔️ サポートされているクエリ演算子のダウンストリーム パイプライン
name string サブクエリ結果テーブルの一時名。

Note

サポートされているクエリ演算子

返品

subquery引数ごとに 1 つずつ、複数の結果テーブル。

ヒント

  • フォーク脚のjoinまたはunionの代わりにmaterializeを使用します。 入力ストリームは materialize によってキャッシュされ、キャッシュされた式は結合または和集合段階で使用できます。

  • fork演算子の代わりに、表形式の式ステートメントのmaterializeバッチを使用します。

名前のないサブクエリ

StormEvents
| where State == "FLORIDA"
| fork
    ( where DeathsDirect + DeathsIndirect > 1)
    ( where InjuriesDirect + InjuriesIndirect > 1)

名前付きサブクエリ

次の例では、結果テーブルの名前は "StormsWithDeaths" と "StormsWithInjuries" になります。

StormEvents
| where State == "FLORIDA"
| fork
    (where DeathsDirect + DeathsIndirect > 1 | as StormsWithDeaths)
    (where InjuriesDirect + InjuriesIndirect > 1 | as StormsWithInjuries)
StormEvents
| where State == "FLORIDA"
| fork
    StormsWithDeaths = (where DeathsDirect + DeathsIndirect > 1)
    StormsWithInjuries = (where InjuriesDirect + InjuriesIndirect > 1)

この機能は、Azure Monitor ではサポートされていません。