---
title: "ezgh obs datasets transforms"
description: "Transform rules: OTTL that reshapes, redacts and drops records at ingest."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.ezghcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ezgh obs datasets transforms

{/* Generated by ezgh-cli's internal/tools/clidocs from the ezgh command tree. Don't edit: change the command's help in ezgh-cli and regenerate. */}

```sh
ezgh obs datasets transforms <command>
```

Transform rules change a dataset's records as they arrive, before they're stored, counted or sampled: drop noise, redact or hash values, reshape attributes and parse log bodies. They're OpenTelemetry Transformation Language (OTTL) statements and drop conditions, per signal (logs, traces, metrics), as the Collector's transform and filter processors take them. A rule can't move records to another dataset: the environment attribute is put back after the rules run. A dataset without rules, or whose rules aren't enabled, stores records as they arrive. Try a draft on sample records with test before you set it. The dataset is given by environment, ID, slug (dst\_…) or name.

Part of [`ezgh obs datasets`](/cli/reference/obs-datasets).

## Flags

This command also takes the [global flags](/cli/reference#global-flags).

## Subcommands

| Command | Description |
| --- | --- |
| [`ezgh obs datasets transforms get`](/cli/reference/obs-datasets-transforms-get) | Show a dataset's transform rules |
| [`ezgh obs datasets transforms set`](/cli/reference/obs-datasets-transforms-set) | Replace a dataset's transform rules from a JSON file |
| [`ezgh obs datasets transforms test`](/cli/reference/obs-datasets-transforms-test) | Try transform rules on sample records without saving them |

Source: https://docs.ezghcloud.com/cli/reference/obs-datasets-transforms/index.mdx
