# NQL比較演算子

比較演算子を [NQLウェア](/platform/ja/understanding-key-data-platform-concepts/nexthink-query-language-nql/nql-keywords/nql-where.md) 句と共に使用して NQL クエリ結果をフィルタリングします。

<table><thead><tr><th width="127.54541015625">演算子</th><th width="154.72723388671875">定義</th><th width="185.3636474609375">サポートされているデータ型</th><th>例</th></tr></thead><tbody><tr><td><code>==</code> または <code>=</code></td><td>等しい</td><td><p>文字列</p><p>整数型（int）</p><p>float</p><p>ブール型（Boolean）</p><p>日付型時間型（date time）</p><p>列挙型（enumeration）</p><p>長さ</p><p>IPアドレス</p><p>バージョン</p></td><td><p><code>| where user.name = "jdoe@kanopy"</code></p><p><code>| where user.name == "jdoe@kanopy"</code></p></td></tr><tr><td><code>!=</code></td><td>等しくない</td><td><p>文字列</p><p>整数型（int）</p><p>float</p><p>ブール型（Boolean）</p><p>日付型時間型（date time）</p><p>列挙型（enumeration）</p><p>長さ</p><p>IPアドレス</p><p>バージョン</p></td><td><code>| where hardware_manufacturer != "VMWare"</code><br><code>| where hardware_manufacturer != null</code></td></tr><tr><td><code>></code></td><td>より大きい</td><td><p>整数型（int）</p><p>float</p><p>長さ</p><p>バイト型（byte）</p><p>IPアドレス</p><p>バージョン</p></td><td><code>| where hardware.memory > 8GB</code></td></tr><tr><td><code>&#x3C;</code></td><td>未満</td><td><p>整数型（int）</p><p>float</p><p>長さ</p><p>バイト型（byte）</p><p>IPアドレス</p><p>バージョン</p></td><td><code>| where hardware.memory &#x3C; 16GB</code></td></tr><tr><td><code>>=</code></td><td>以上</td><td><p>整数型（int）</p><p>float</p><p>日付型時間型（date time）</p><p>長さ</p><p>バイト型（byte）</p><p>IPアドレス</p><p>バージョン</p></td><td><code>| where hardware.memory >= 8GB</code></td></tr><tr><td><code>&#x3C;=</code></td><td>以下</td><td><p>整数型（int）</p><p>float</p><p>日付型時間型（date time）</p><p>長さ</p><p>バイト型（byte）</p><p>IPアドレス</p><p>バージョン</p></td><td><code>| where hardware.memory &#x3C;= 16GB</code></td></tr></tbody></table>

詳細については、[NQLデータタイプ](/platform/ja/understanding-key-data-platform-concepts/nexthink-query-language-nql/nql-syntax-overview/nql-data-types.md) を参照してください。

{% hint style="info" %}
比較操作では、`=` と `==` は互換性があります。 ただし、[NQL計算](/platform/ja/understanding-key-data-platform-concepts/nexthink-query-language-nql/nql-keywords/nql-compute.md) または [NQLサマライズ](/platform/ja/understanding-key-data-platform-concepts/nexthink-query-language-nql/nql-keywords/nql-summarize.md) ステートメントでエイリアスを使用する場合は、単一の `=` のみがサポートされます。
{% endhint %}

これらの演算子と組み合わせて使用されるすべての式は大文字小文字を区別しません。 たとえば、次のクエリは同じ結果を返します。

{% code overflow="wrap" lineNumbers="true" %}

```
過去24時間以内のデバイス
| where name = "CORPSYS2022"
```

{% endcode %}

{% code overflow="wrap" lineNumbers="true" %}

```
過去24時間以内のデバイス
| where name == "CoRpSyS2022"
```

{% endcode %}

### ワイルドカードの使用

ワイルドカードを使用して部分的な値を一致させ、フィルターの柔軟性を高めます。 比較演算子と組み合わせて使用される式は、以下のワイルドカード文字をサポートしています。

<table><thead><tr><th width="109">演算子</th><th width="189.36358642578125">定義</th><th>例</th></tr></thead><tbody><tr><td>*</td><td>任意の文字列を置き換えます</td><td><p><code>| where application.name = "Microsoft*"</code></p><p>"Microsoft" で始まるアプリケーション名を返します</p><p><code>| where application.name = "*Microsoft*"</code></p><p>"Microsoft" を含むアプリケーション名を返します</p></td></tr><tr><td>?</td><td>任意の1文字を置き換えます</td><td><p><code>| where device.operating_system.name == "Windows 1?"</code></p><p>Windows 10 や Windows 11 などの10以上のバージョンのオペレーティングシステム名を返します。</p></td></tr><tr><td>...</td><td></td><td></td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.nexthink.com/platform/ja/understanding-key-data-platform-concepts/nexthink-query-language-nql/nql-operators/nql-comparison-operators.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
