# Datetime

Below is a list of available datetime mask functions.

## **Hasher**

The Hasher anonymizes datetime values by applying a random offset while maintaining consistency. This ensures that the relative differences between timestamps remain intact while preventing direct identification of the original values. To ensure accurate ordering, please see [ordering and indexing considerations](https://docs.syntho.ai/configure-a-data-generation-job/consistent-mapping#ordering-and-indexing-considerations).

#### **Parameters**

* No parameters.

#### **Example** <a href="#example---shifting-a-set-of-dates" id="example---shifting-a-set-of-dates"></a>

If you configure:

```
Column names:
1951-12-07,
1966-12-26,
1971-09-23,
...
```

The results will be:

```
Column names:
1957-06-18,
1943-07-30,
2015-09-01,
...
```

<figure><img src="https://content.gitbook.com/content/U61B9DqtWCNO3Z30vnjh/blobs/UhJgJf06aikkab8GV9OP/image.png" alt="" width="529"><figcaption><p>Hasher</p></figcaption></figure>

## **Datetime Noise**

Adds a random shift to a datetime value based on specified minimum and maximum shift parameters.

#### **Parameters**

* `Maximum negative noise`: The smallest amount the date can be adjusted, relative to the original date.
  * Use negative numbers to shift the date into the past.
    * Example: If the date part is set to "Day" and the minimum shift is set to `-5`, this ensures the date will not be shifted earlier than 5 days prior to the original date.
    * A positive number shifts the date forward.
    * Example: If the minimum shift is `5`, the date will not shift earlier than 5 days after the original date.
* `Maximum positive noise`: The largest amount by which the date can be adjusted from the original value.
  * Use positive numbers to shift the date into the future.
    * Example: If the date part is set to "Day" and the maximum shift is set to `5`, the date will not be shifted later than 5 days after the original date.
* `Noise type`: The unit of time (e.g., second, minute, hour day, month, year) that will define the granularity of the shift.
  * The selected unit will be applied to both the minimum and maximum shift fields.
* `Consistent mapping`: Datetime Noise supports [consistent mapping](https://docs.syntho.ai/configure-a-data-generation-job/configure-column-settings/consistent-mapping).

#### **Example** <a href="#example---shifting-a-set-of-dates" id="example---shifting-a-set-of-dates"></a>

If you configure:

```
Maximum negative noise: 2
Maximum positive noise: 2
Noise type: Day

1951-12-07,
1966-12-26,
1971-09-23,
...
```

The results will be:

```
1951-12-05,
1966-12-26,
1971-09-23,
...
```

<figure><img src="https://content.gitbook.com/content/U61B9DqtWCNO3Z30vnjh/blobs/UZEPoBMV7n3knUOEF2sB/image.png" alt="" width="525"><figcaption><p>Datetime Noise</p></figcaption></figure>
