Creating a column mask for a column in a table


Use the following procedure to create a mask for a column.

  1. On the BMC AMI Change Manager for Db2 Main Menu, select WORKID, and press Enter.
  2. On the WORKID Action Menu, type the name of the existing WORKID or type a wildcard pattern to display a list of work IDs. Then, select Specify Db2 definitions and press Enter.
  3. On the Object Specification panel, specify the name of a database and table (or use wildcard characters). Then, press Enter.
  4. On the Mixed List panel, type CMK in the Act column adjacent to the table (TB) on which you want to add a column mask.
  5. On the Create Column Mask panel, specify the information about the mask.
    1. Type the schema of the mask.
    2. Type the name of the mask.
    3. Type the name of the column for the mask. Alternatively, you can select the column by typing ? in the field or by using the Table Column List option.
    4. (optional) In the Cor Name field, type the correlation name for the table.
    5. (optional) In the Enable field, type Y to activate the permission.
  6. On the Create Column Mask panel, type S to select the Column Mask Text panel and one or more of the following panels:
    • Schema Path
    • Comments
  7. Press Enter to proceed to the next panel.
  8. Enter the case expression for the column mask in the editor as shown in the following figure.

    ****** ***************************** Top of Data ******************************
    ====== CREATE MASK <schema>.<maskName>           
    ====== ON <tableOwner>.<tableName>    
    ====== FOR COLUMN <columnName>        
    ====== RETURN                    
    000001   CASE WHEN               
    000002   THEN                    
    000003   ELSE                    
    000004   END                     
    ====== DISABLE   
    ****** **************************** Bottom of Data ****************************
  9. Press END to proceed to the next panel or return to the Create Column Mask panel.
  10. Press END.
  11. The Mixed List panel is displayed, as shown in the following figure.

     DEJM ALTER   --------------------------- Mixed List ---------------------------
     Command ===>                                                    Scroll. . PAGE
                                                                                   
     WORKID  . . . . : MVSSXS1.SCB0522A                            Commands: CANCEL
                                                                                   
     Type action next to object and press Enter.                                    
        E=Edit  L=Like  D=Drop  U=Undo                                              
                                                             Objects 1 to 13 of 13  
                                                                      More:         
     Act     Object-Type    Objects                                                 
     ************************************ TOP **************************************
             DB . . . . . . S1BASIC                                                 
               TB . . . . .   S1BASIC    T_T10AIM                                   
               TB . . . . .   S1BASIC    T_T01AICP                                  
         *L      MK . . . .     S1BASIC    MK_T01AICP                               
               TB . . . . .   S1BASIC    T02ASSEG                                   
               TB . . . . .   S1BASIC    T_T03AMSEG_A                               
               TB . . . . .   S1BASIC    T_T03AMSEG_B                               
               TBT. . . . .   S1BASIC    T_T04ATCP                                  
               TBT. . . . .   S1BASIC    T_T05APBR                                  
               TB . . . . .   S1BASIC    T_T06APBG                                  
               TB . . . . .   S1BASIC    T_T07APBG                                  
               TBT. . . . .   S1BASIC    T_T08APBR                                  
               TBT. . . . .   S1BASIC    T_T15APBR                                  
     *********************************** BOTTOM ************************************
                                                                                    

    The new column mask, designated by the MK object type, is displayed below the table object.

  12. Press END until the WORKID Action Menu is displayed.Now that a column mask has been created, you can analyze the work ID and execute the worklist.



 

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