> For the complete documentation index, see [llms.txt](https://docs.ngsurvey.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ngsurvey.com/fr/form-management/form-designer/answers/answer-types/compare-field.md).

# Champ de comparaison

Le type de réponse « compare field » vous permet de comparer la saisie du Répondant dans ce champ avec la saisie d’un autre champ du Sondage ou de la comparer à une valeur fixe ou à un intervalle de valeurs que vous définissez.

![](https://186103257-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MBy9K6mPB7MITp_lb-s%2F-MBy9S2IyW6oyJ5j1ZeC%2Fimage.png?alt=media\&token=6f6d33d5-2982-4766-946b-1e5d6dd79610)

Dans l’exemple ci‑dessus, « Confirm password » est le compare field et comparera sa valeur avec le champ Password pour s’assurer qu’elles correspondent.

## 👥 Comparer à une autre valeur de réponse

Pour comparer une valeur provenant d’une autre réponse, vous devez ouvrir sa [propriétés de la réponse](/fr/form-management/form-designer/answers/answer-properties.md) page et définir son **Answer label** sur le champ auquel vous souhaitez comparer.

![](https://186103257-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MBy9aPXIDWP9xgiKEHK%2F-MBy9qMYm2H07Il2Yo0E%2Fimage.png?alt=media\&token=f14b4218-7b14-4c5a-a91a-1c760d8520d9)

Dans l’exemple ci‑dessus, le compare field comparera la valeur saisie dans la réponse Password et vérifiera qu’elle est égale à la valeur saisie dans le compare field.

## 🔢 Comparer à une valeur statique

Pour comparer une valeur statique à la réponse du Répondant, vous devez ouvrir sa [propriétés de la réponse](/fr/form-management/form-designer/answers/answer-properties.md) page et définir le **Respondent answer** ou **Respondent answer range** sur&#x20;

![](https://186103257-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MBy9aPXIDWP9xgiKEHK%2F-MByBJ1QbLQEV4meSN-f%2Fimage.png?alt=media\&token=01e6ca43-a55b-4639-b055-926186f173b2)

Dans l’exemple, le compare field comparera la saisie du Répondant et s’assurera qu’elle est égale à 10.

Vous pouvez utiliser les conditions suivantes pour votre comparaison.

![](https://186103257-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8fLhS0bmfBRyq0HdUm%2F-MBy9aPXIDWP9xgiKEHK%2F-MByBc7Az10WMD705WiF%2Fimage.png?alt=media\&token=17095c72-15dd-46ee-808d-b53eeeacf34f)

{% hint style="info" %}
Les comparaisons dépendent du type : si vous avez sélectionné par exemple le type numérique alors 10 serait supérieur à 9 ; si c’était une date alors le 2 juin serait postérieur au 1er juin.
{% endhint %}


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.ngsurvey.com/fr/form-management/form-designer/answers/answer-types/compare-field.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
