# Max (Decimal)

| **Name**    | ***Max (Decimal)***                                                                        |
| ----------- | ------------------------------------------------------------------------------------------ |
| Syntax      | Max (Decimal first, Decimal second)                                                        |
| Purpose     | To return the greater of two decimal values.                                               |
| Description | Returns the maximum of two decimal values.                                                 |
| Return Type | Decimal                                                                                    |
| Parameters  | <p>first \[System.Decimal] – First value</p><p>second \[System.Decimal] – Second value</p> |

![](https://content.gitbook.com/content/zEifS4h8yurLAAwiGNX2/blobs/OZB9EhHZW1ftv2z9D9HE/0.png)

**Example**

In this example, we are passing decimal values to the function transformation object using a *Variables* object.

**Note:** This function also takes into account negative values.

Where,

*first* = 1.23

*second* = 3.21

<figure><img src="https://content.gitbook.com/content/zEifS4h8yurLAAwiGNX2/blobs/OZmcDu0OF86CPwDPvSks/1.png" alt=""><figcaption></figcaption></figure>

In the output window, you can see that the greater decimal value has been returned.

<figure><img src="https://content.gitbook.com/content/zEifS4h8yurLAAwiGNX2/blobs/tRJKc3X6EyKAe1NLc2H9/2.png" alt=""><figcaption></figcaption></figure>
