{
  "id": "map",
  "title": "map",
  "url": "https://redis.io/docs/latest/integrate/redis-data-integration/reference/data-transformation/map/",
  "summary": "Map a record into a new output based on expressions",
  "tags": [
    "docs",
    "integrate",
    "rs",
    "rdi"
  ],
  "last_updated": "2026-04-01T08:10:08-05:00",
  "page_type": "content",
  "content_hash": "a51cc5a2acc653399dce131a6f7b5d8f86362668c279e56183f6cb45ed5f7bfc",
  "sections": [
    {
      "id": "overview",
      "title": "Overview",
      "role": "overview",
      "text": "Map a record into a new output based on expressions\n\n**Properties**\n\n| Name                          | Type               | Description                                   | Required |\n| ----------------------------- | ------------------ | --------------------------------------------- | -------- |\n| [**expression**](#expression) | `object`, `string` | Expression<br/>                               | yes      |\n| **language**                  | `string`           | Language<br/>Enum: `\"jmespath\"`, `\"sql\"`<br/> | yes      |\n\n**Additional Properties:** not allowed\n\n**Example**\n\n[code example]\n\n**Example**\n\n[code example]\n\n<a name=\"expression\"></a>"
    },
    {
      "id": "expression-object",
      "title": "expression: object",
      "role": "content",
      "text": "Expression\n\n**No properties.**"
    }
  ],
  "examples": [
    {
      "id": "overview-ex0",
      "language": "yaml",
      "code": "source:\n  schema: dbo\n  table: emp\ntransform:\n  - uses: map\n    with:\n      expression:\n        first_name: first_name\n        last_name: last_name\n        greeting: >-\n          'Hello ' || CASE WHEN gender = 'F' THEN 'Ms.' WHEN gender = 'M' THEN 'Mr.'\n          ELSE 'N/A' END || ' ' || full_name\n        country: country\n        full_name: full_name\n      language: sql",
      "section_id": "overview"
    },
    {
      "id": "overview-ex1",
      "language": "yaml",
      "code": "source:\n  table: customer\ntransform:\n  - uses: map\n    with:\n      expression: |\n        {\n          \"CustomerId\": customer_id,\n          \"FirstName\": first_name,\n          \"LastName\": last_name,\n          \"Company\": company,\n          \"Location\":\n          {\n            \"Street\": address,\n            \"City\": city,\n            \"State\": state,\n            \"Country\": country,\n            \"PostalCode\": postal_code\n          },\n          \"Phone\": phone,\n          \"Fax\": fax,\n          \"Email\": email\n        }\n      language: jmespath",
      "section_id": "overview"
    }
  ]
}
