How to map a Source Event Type with a Destination Table using Schema Mapper
You can follow these steps for mapping a Source Event Type with a Destination Table using the Schema Mapper:
1. Select an Event
From the Schema Mapper Overview screen select the Unmapped event type you want to map to a destination table.
2. Select Destination Table
The Mapping Summary widget on the right will show the selected event, its fields, and field attributes.
The widget will also allow you to map the source table to a destination table. This can be done by two ways:
- Selecting an existing table from the Destination Table drop-down. Skip directly to step 4 if you choose this option.
- Creating a new table by clicking on CREATE NEW TABLE button present at the bottom within the destination table drop-down.
3. Create a New Table
Upon clicking CREATE NEW TABLE, you will be asked for Table Name, Columns, Data Type, Primary keys, and other information that is needed to create a table in the destination.
All the fields from the source are automatically detected by Hevo and a mapping suggestion is provided to you.
- If you want to change the Table Name, you can type into the Table Name input box.
- If you want to customize the data type of column you have an option to change it from the Data Type drop-down. Hevo displays only compatible data types.
- You can select the Primary Keys, and other keys for the table.
- If you do not want to add a column just click on the Delete icon towards the end of the row.
Finally, click on Create Table to create the table. The newly created table will appear in the Destination Table drop-down in the Mapping Summary Widget.
Alternatively, if you want to cancel the creation of the new table click on the Cancel button.
4. Map Fields
Once you have selected a destination table you need to specify how the individual columns will be mapped between the source event type and the destination table. This step may not be required at all if you created a new table in step 3 and choose to use the column names suggested by Hevo.
You can read more about mapping a Source Event Type field with a Destination Table Column here.
5. Create Mapping
- Once you are done with mapping the fields click on Create Mapping.
- Any new fields which are not present in the destination table will be created.
- Your data will start replicating in the destination as per the mappings defined by you.