Copy Column Selection


The Copy Column Selection screen appears when you specified at the Table Copy Selection screen to create temporary selection criteria and enter selection criteria on the template, and also entered in the Column Selection field (see Table-Copy-Selection). It lets you map columns from one table to another.

If you have specified Y in the Column Name Matching field and the column names and data types are identical, they are mapped to the screen in the original order (see the Map field). If column names and data types are not identical, or you specified N in the Column Name Matching field, you must indicate which columns are to be mapped by inserting the appropriate integers in the Map field.

Unmatched column names that are defined as NOT NULL are initialized with a map value of D, meaning that they will be set to the default value for the data type.

To copy from or into distinct type columns both columns must have the same UDT with identical schema, name and built-in data type.

You can execute the SQL primary command on this screen to view or save the SQL File-AID for Db2 generated to complete the task.

Copy Column Selection screen

image2021-3-10_16-45-39.png

From Table

Name of the table or view to be copied.

To Table

Name of the table or view to which the From Table is being copied.

From Table Columns

Columns to be copied.

Data Type

Data types and lengths of the columns to be copied.

Map

Specify in what order the columns of the From Table are to be mapped. Type in the column numbers of the From Table, or enter D to fill in a default value.

To Table Columns

Names of the columns to which you are copying.

Data Type

Data types and lengths of the columns to which you are copying.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*