> For the complete documentation index, see [llms.txt](https://docs.appmixer.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.appmixer.com/connector-configuration/utils/filters/greater-than.md).

# Greater Than

### Overview

The **Greater Than Filter Component** checks whether a given input data is greater than a specified value. If the condition is met, the message is passed through the `greater` port; otherwise, it is routed to `notGreater`.

### Usage

This component is used to validate if a text, number, or date is greater than a predefined value, making it useful for conditional processing in workflows.

#### Properties

| Property      | Type      | Description                                                                                                                   |
| ------------- | --------- | ----------------------------------------------------------------------------------------------------------------------------- |
| `sourceData`  | `string`  | The data to be compared. Can be a number or date.                                                                             |
| `greaterThan` | `string`  | The value to compare against `sourceData`.                                                                                    |
| `exclusive`   | `boolean` | If `true`, only values strictly greater than `greaterThan` pass through. If `false`, values equal to `greaterThan` also pass. |

#### Input Ports

| Port | Description                                          |
| ---- | ---------------------------------------------------- |
| `in` | Accepts input data and the value to compare against. |

#### Output Ports

| Port         | Description                                                                                |
| ------------ | ------------------------------------------------------------------------------------------ |
| `greater`    | Emits the message if `sourceData` is greater than (or equal to, by default) `greaterThan`. |
| `notGreater` | Emits the message if `sourceData` is not greater than `greaterThan`.                       |

#### Processing Logic

1. **Receives Input Data**:
   * Accepts a dataset (`sourceData`) and a comparison value (`greaterThan`).
2. **Checks for Greater Condition**:
   * If both values are numbers, compares them numerically.
   * If both values are dates, checks if `sourceData` is after `greaterThan`.
   * If `exclusive` is set to `true`, strict greater-than comparison is applied.
3. **Routes the Message**:
   * If `sourceData` is greater than `greaterThan`, the message is passed to the `greater` port.
   * Otherwise, it is passed to the `notGreater` port.

#### Output Data Schema

| Property      | Type      | Description                                                              |
| ------------- | --------- | ------------------------------------------------------------------------ |
| `sourceData`  | `string`  | The original data that was checked.                                      |
| `greaterThan` | `string`  | The value compared against `sourceData`.                                 |
| `result`      | `boolean` | `true` if `sourceData` is greater than `greaterThan`, otherwise `false`. |

### Notes

* **Supports Numeric & Date Comparisons**: Compares numbers and dates effectively.
* **Configurable Strict Comparison**: The `exclusive` property determines whether equality should be considered.
* **Ideal for Conditional Filtering**: Useful in workflows requiring data validation based on numeric or date values.

This component is essential for workflows that need to filter or route messages based on whether a value exceeds a predefined threshold.


---

# 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.appmixer.com/connector-configuration/utils/filters/greater-than.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.
