How to Add Column to Target Database
Question
How to add a column to the target database that corresponds to a column added to the existing source database?
Environment
HVR
Problem Summary
A source DB that had replication running was upgraded and a table has been recreated in the source DB with an extra column. Our capture process was suspended during the source database upgrade. When restarting the capture, HVR successfully identifies that a table (that has been in our sync config) has been dropped and recreated again with an extra column.
Now I'm trying to get this extra column also at the target side by adding it to the table config and running HVR Initialize, but I am not able to add this column at the target side.
Can you please help me with the procedure to add this column at the target side?
Answer
If you have action AdaptDDL defined on your channel, then it will take care of structure synchronization without any manual intervention.
However, if AdaptDDL is not defined, you can add this column with the following steps:
- In Table Explore dialog, select the source location and click Connect. The table that changed will be highlighted as Extra Column.
- Select that line, then click Replace (at bottom of the screen) to add the new column.
- Run HVR Initialize for the Capture and Integrate location with options Scripts and Jobs and Table Enrollment selected.
- Perform an Online Refresh with option If Mistmatched selected for the affected table. This will be necessary to get the data and layout back in sync.