> For the complete documentation index, see [llms.txt](https://docs.pentaho.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.pentaho.com/pdia-data-integration/9.3-data-integration/pdi-transformation-steps-reference-overview/simple-mapping-sub-transformation.md).

# Simple Mapping (sub-transformation)

As you build a transformation, you may notice a sequence of steps you want to repeat. This sequence can be turned into a mapping.

Just like the [Mapping](https://docs.pentaho.com/pdia-data-integration/9.3-data-integration/pdi-transformation-steps-reference-overview/mapping.md) step, you can use the Simple Mapping (sub-transformation) step to turn the repetitive, re-usable part of a transformation into a mapping.

Compared to the Mapping step, the Simple Mapping (sub-transformation) step accepts one and only one input and output step. As such, it behaves like any other regular step which reads and writes rows of data.

Also, as with the Mapping step, input and output are defined by the following placeholder steps:

* [**Mapping input step**](https://docs.pentaho.com/pdia-data-integration/9.3-data-integration/pdi-transformation-steps-reference-overview/mapping/mapping-input-specification.md)

  a placeholder where the mapping expects input from the parent transformation.
* [**Mapping output step**](https://docs.pentaho.com/pdia-data-integration/9.3-data-integration/pdi-transformation-steps-reference-overview/mapping/mapping-output-specification.md)

  a placeholder from where the parent transformation can read data.

The mapping executed by the parent transformation through the Simple Mapping (sub-transformation) step is known as the sub-transformation.

You can run the Simple Mapping (sub-transformation) step in multiple copies, clusters, in single threading mode, or in any other execution model. You can also use this step in advanced data routing scenarios (filter rows and switch/case for example) or in partitioning or partitioning/clustering transformations.


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.pentaho.com/pdia-data-integration/9.3-data-integration/pdi-transformation-steps-reference-overview/simple-mapping-sub-transformation.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
