> For the complete documentation index, see [llms.txt](https://help.adalo.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.adalo.com/ja/integrations/sheetbridge-for-google-sheets/sort-and-filter-your-sheetbridge-data.md).

# SheetBridgeデータの並べ替えとフィルター

### **クエリパラメータ**

**クエリパラメータ**の設定画面にて、列名と値を指定し、以下の**演算子（Operators）**&#x3092;使用することでリストをフィルターできます。

以下の例は、「user\_id」列がMagicTextの「LoggedInUser>id」と一致する行を抽出します。

<div align="center"><figure><img src="/files/2yyuk0FpGtDHsscz61CV" alt="" width="333"><figcaption></figcaption></figure></div>

***

### **演算子（Operators）**

高度なフィルタリングを行うには、以下の演算子を使用します。

| **演算子**         | **説明**   | クエリパラメータ名                     | クエリパラメータの値           |   |
| --------------- | -------- | ----------------------------- | -------------------- | - |
| **`_eq`**       | 一致する     | **`filter[user_id][_eq]`**    | **`John`**           |   |
| **`_neq`**      | 一致しない    | **`filter[Name][_neq]`**      | **`John`**           |   |
| **`_contains`** | 部分一致する   | **`filter[Name][_contains]`** | **`John`**           |   |
| **`_in`**       | リストに含まれる | **`filter[Status][_in]`**     | **`active,pending`** |   |
| **`_null`**     | 空である     | **`filter[Email][_null]`**    | **`true`**           |   |
| **`_notnull`**  | 空ではない    | **`filter[Email][_notnull]`** | **`true`**           |   |
| **`_gt`**       | より大きい    | **`filter[Age][_gt]`**        | **`18`**             |   |
| **`_gte`**      | 以上       | **`filter[Age][_gte]`**       | **`18`**             |   |
| **`_lt`**       | 未満       | **`filter[Age][_lt]`**        | **`65`**             |   |
| **`_lte`**      | 以下       | **`filter[Age][_lte]`**       | **`65`**             |   |

{% hint style="info" %}
&#x20;**`_eq`** 演算子は、カンマ区切りの値もサポートしています（**`_in`** のように動作します）。ユーザーが **`filter[Status][_eq]=active,pending`** を渡した場合、どちらかの値に一致する行が抽出されます。
{% endhint %}

***

#### **複数のフィルター**

**「+ADD ANOTHER FILTER」**&#x3092;使用することで、複数のフィルターを組み合わせることができます。

以下の例は、「user\_id」列がMagicTextの「LoggedInUser>id」と**一致**し、**かつ（AND）**「category」列が「Instruments」と**一致しない**行をリストアップします。両方の条件が満たされない場合、そのレコードは読み込まれません。

<div align="center"><figure><img src="/files/oaGylrvYwOKjFME1fiLa" alt="" width="287"><figcaption></figcaption></figure></div>

### **並べ替え**

リストフィルター内の <mark style="color:red;">**`sort`**</mark> クエリパラメータを使用することで、行を並べ替えることができます。並べ替えはフィルタリングが実行された後に適用され、単一または複数の列をサポートしています。

#### **単一列の並べ替え**

* 単一の列を昇順で並べ替える場合：

<figure><img src="/files/EoQQDDcTpoj0RuJu6QG3" alt="" width="290"><figcaption></figcaption></figure>

* 単一の列を降順で並べ替える場合（先頭に **`-`** を付けます）：

<figure><img src="/files/CnUkSSbu6Yh7gBNQ5jjr" alt="" width="287"><figcaption></figcaption></figure>

***

#### **複数列の並べ替え**

複数の列をカンマで区切ることで、複数の列による並べ替えが可能です。列は優先順位の高い順に並べ替えられます。

<figure><img src="/files/1mH2qgXa2w3SOBKnp76K" alt="" width="282"><figcaption></figcaption></figure>

これは以下のように並べ替えられます。

1. **`name`** を昇順で並べ替え
2. **`user_id`** を降順で並べ替え（同じ name を持つ行に対して適用）

***

#### **列名の解決**

列名は、フィルタリングと同じヘッダーマッピングシステムを使用して解決されます。

* 正規化されたヘッダー（スペースが削除され、小文字に変換されたもの）
* 標準キー（Canonical keys）
* 大文字・小文字を区別しないラベルマッチング

以下のどのフォーマットでも使用できます。

* 元の列ラベル：**`?sort=Full Name`**
* 正規化されたヘッダー：**`?sort=fullname`**
* 標準キー：**`?sort=full_name`**

***

#### **値の比較**

並べ替えサービスは、値をスマートに比較します。

* **数値（Numeric values）：**&#x6570;値として並べ替えられます（例：**`2`**&#x306F;**`10`**&#x306E;前に来ます）
* **文字列（String values）：**&#x5927;文字と小文字を区別せずに並べ替えられます（例：「**`apple`**」と「**`Apple`**」は同じものとして扱われます）
* **Null値（Null values）：**&#x4E26;べ替え結果の常に最後尾に配置されます

***

#### **他のパラメータとの組み合わせ**

並べ替えはフィルタリングと組み合わせることができます。

<figure><img src="/files/p9TzeDouhwJfMEWC3f0Y" alt="" width="286"><figcaption></figcaption></figure>

これにより、以下が実行されます。

* 「**`user_id`**」が **`LoggedinUser>id`** と一致する行をフィルターします。
* 結果を「**`name`**」の降順で並べ替えます。

***

#### **未知の列**

シートに存在しない列を指定した場合、それは自動的に無視されます。リクエスト自体は成功しますが、その並べ替え指示は効果を持ちません。


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://help.adalo.com/ja/integrations/sheetbridge-for-google-sheets/sort-and-filter-your-sheetbridge-data.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
