> For the complete documentation index, see [llms.txt](https://docs-embed.anyflow.jp/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs-embed.anyflow.jp/solution-editor/common-specs/fixed-list-dynamic-list.md).

# 固定リストと動的リスト

## **概要**

一部のアクションでは、フィールドの設定する際に、入力としてリスト（変数）を設定します。\
（例:Salesforce,kintone,カオナビの一括挿入や一括更新、一括削除など）

<figure><img src="https://files.readme.io/2819f11-field-list-select-dynamic-lists.png" alt="575"><figcaption><p><code>リスト</code>の「︙」を押下すると、<code>固定リスト</code>か<code>動的リスト</code>を選択するウィンドウが表示されます。</p></figcaption></figure>

### **リストを設定する際の選択基準**

<table><thead><tr><th width="468.2890625">パターン</th><th>リスト</th></tr></thead><tbody><tr><td>フォームの総数と内容がわかっている場合</td><td>固定リスト</td></tr><tr><td>フォームの数と内容が他のリストに依存する場合</td><td>動的リスト</td></tr></tbody></table>

## **動的リスト**

アクションでリスト内のすべての項目を動的に反復し、すべての行の値を読み取る場合は、`動的リスト`を選択します。\
（例:10行のCSVファイルがある場合、動的リストはすべての行を反復処理し、各行のデータを使用してSalesforceに10個の新しいレコードを作成します。）

### **使い方**

リストで`動的リスト`を選択すると、`ソースリスト` というフィールドが入力可能になります。\
`リストソース`はリスト（変数）のみ設定可能です。

<figure><img src="https://files.readme.io/c70383b-list-source-mapping.png" alt="475"><figcaption><p><code>リストソース</code>で変数（マッピング）を設定します。</p></figcaption></figure>

<figure><img src="https://files.readme.io/a60a2cf-list-source-input.png" alt="959"><figcaption><p><code>リストソース</code>に設定した変数を選択します。</p></figcaption></figure>

リスト（変数）を使用すると、ソースするコネクタのオブジェクトリストから直接データを取得します。\
その後、リスト（変数）として取得した変数を使用して、以下フィールドをマッピングします。

<figure><img src="https://files.readme.io/2a14a4a-object-mapping.png" alt="961"><figcaption><p><code>マッピング</code>の<code>i番目のマッピング</code>から、対応するカラムを選択します。</p></figcaption></figure>

### **利用例**

#### **実行ボタンを押したユーザーの情報から、Salesforceでレコードを作成する場合の例**

実行ボタンを押したユーザーの情報を取得し、Salesforceでレコードを作成します。\
複数のデータがある場合に、全データをループし、値を取得する形となります。

**ソリューションでの設定方法**\
[こちら](#i)と同様の設定をします。\
エンドユーザー変数の詳細の設定方法については、[こちら](/solution-editor/about.md)をご確認ください。

<figure><img src="https://files.readme.io/a08a220-dynamic-lists-solution.png" alt=""><figcaption></figcaption></figure>

要素フィールドのオブジェクトを設定します。\
`フィールド名`と`値`が対応する形にします。

**ウィザードでの設定方法**\
ウィザードでは以下の設定が必要になります。

* [ウィザードを構築する](/wizard-editor/about.md)
* [エンドユーザー変数を設定する](/wizard-editor/widget.md)

***

## **固定リスト**

`動的リスト`とは対照的に、フォームの総数内容がわかっている場合は`固定リスト`を使用します。\
この場合、各項目が1つずつ追加されます。

<figure><img src="https://files.readme.io/23b62d4-field-list-select-fixed-lists.png" alt="575"><figcaption><p><code>リスト</code>の「︙」を押下し、<code>固定リスト</code>を選択します。</p></figcaption></figure>

### **使い方**

`固定リスト`は、リスト内の各項目を 1 つずつ追加してマッピングする必要があります。\
エンドユーザー変数や、他アクション/トリガーで取得した情報を、変数ウィンドウから選択し設定します。

<figure><img src="https://files.readme.io/f3e9449-fixed-lists-mapping.png" alt="574"><figcaption><p>対応する<code>フィールド名</code>と<code>値</code>を設定します。</p></figcaption></figure>

### **利用例**

#### **実行ボタンを押したユーザーの情報から、Salesforceでレコードを作成する場合の例**

実行ボタンを押したユーザーの情報を取得し、Salesforceでレコードを作成します。

**ソリューションでの設定方法**\
[こちら](#i-1)と同様の設定をします。\
エンドユーザー変数の詳細の設定方法については、[こちら](/solution-editor/about.md)をご確認ください。

<figure><img src="https://files.readme.io/5f96f0e-fixed-lists-mapping-example.png" alt="539"><figcaption><p>各項目を1つずつ設定します。</p></figcaption></figure>

アイテムを追加したい場合は、`追加`ボタンを押下し、同様の設定を行います。

<figure><img src="https://files.readme.io/34b75ef-fixed-lists-mapping-add.png" alt=""><figcaption></figcaption></figure>

**ウィザードでの設定方法**\
ウィザードでは以下の設定が必要になります。

* [ウィザードを構築する](/wizard-editor/about.md)
* [エンドユーザー変数を設定する](/wizard-editor/widget.md)

今回は、Salesforceのオブジェクトとフィールドの設定には、`アシスト`を使用します。\
ソリューションで設定したアイテムの`フィールド`と`値`が対応する形で設定します。

これにより、エンドユーザー側でオブジェクトとフィールドを検索し、選択することが可能です。

<figure><img src="https://files.readme.io/94f5bab-fixed-lists-assist.png" alt="1440"><figcaption><p>エンドユーザーのオブジェクトとフィールドの選択画面</p></figcaption></figure>


---

# 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://docs-embed.anyflow.jp/solution-editor/common-specs/fixed-list-dynamic-list.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.
