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

# SQL transformations and revisions

> Create destination-owned SQL drafts, validate and preview output, then publish isolated revisions.

The current transformation workflow is destination-owned and revision-based.
There is no canvas transformation node and no separate Normalisation panel.

## Create a transformation

1. Open **Transformations**.
2. Select a destination in the left navigator.
3. Click **New transformation**.
4. Enter a name, stable key, and output model.
5. Select one or more source input streams.
6. Write the SQL model.
7. Click **Save draft**.

## Release a revision

Use the editor's release workflow in order:

1. **Validate draft** checks SQL and the output model.
2. **Preview output** runs the valid draft and shows its result.
3. **Publish revision** makes that revision available to the owning destination's next run.

Unsaved or unpublished drafts do not change production runs. Revision history
keeps earlier releases visible.

## Rename and cast values

Express renames and casts directly in SQL:

```sql theme={"theme":{"light":"github-light","dark":"github-dark"}}
SELECT
  id,
  status AS order_status,
  CAST(total_amount AS DECIMAL(12, 2)) AS total_amount
FROM {{ source('raw', 'public__orders') }}
```

Use SQL for filtering, joins, JSON extraction, derived fields, aggregates, and
final output selection. See [SQL transformations](/pipelines/dbt-layer).

## Assign the published output

After publishing, open the owning destination. Under **Published output
targets**, enter the final table and Upsert keys, or configure Airtable field
mappings and merge fields. Final destination tables must exist before delivery.
