Back to Redis

Rename Field

content/integrate/redis-data-integration/reference/data-transformation/rename_field.md

latest1.5 KB
Original Source

Rename fields. All other fields remain unchanged.

Option 1 (alternative): Rename multiple fields

Properties

NameTypeDescriptionRequired
fieldsobject[]Fields
yes

Additional Properties: not allowed
Example

yaml
source:
  schema: dbo
  table: emp
transform:
  - uses: rename_field
    with:
      fields:
        - from_field: name.lname
          to_field: name.last_name
        - from_field: name.fname
          to_field: name.first_name

Option 2 (alternative): Rename one field

Properties

NameTypeDescriptionRequired
from_fieldstringFrom field
yes
to_fieldstringTo field
yes

Additional Properties: not allowed

Example

yaml
source:
  schema: dbo
  table: emp
transform:
  - uses: rename_field
    with:
      from_field: name.lname
      to_field: name.last_name

<a name="option1fields"></a>

Option 1: fields[]: array

Fields

Items

Item Properties

NameTypeDescriptionRequired
from_fieldstringFrom field
yes
to_fieldstringTo field
yes

Item Additional Properties: not allowed

Example

yaml
- {}