Previous Topic: Revert Schema ModificationsNext Topic: How to Customize Web Interface using Web Screen Painter


Modify Site-Defined Columns after Publishing

After site-defined schema modifications are published, WSP treats them similarly to the standard schema and restricts further changes. You can delete a site-defined column or can change the length of a site-defined string column by manually updating the DBMS and schema external to WSP. Then you run the pdm_wspupd script to update the database wspcol table to synchronize WSP with the external changes.

Follow these steps:

  1. Log in to the following server, depending upon your CA SDM configuration:
  2. Find the site/mods subdirectory in your CA SDM installation directory.
  3. Edit the wsp_schema.sch file to delete unwanted site-defined columns or change the length of site-defined STRING columns. These updates are the only changes supported by this procedure. You can use any standard text editor to edit the wsp_schema.sch file.

    Important! If any of the index options (such as, UNIQUE) were specified for deleting a column, edit the wsp_index.sch file and remove references to the column. If the column was the only indexed column in the table, remove all references to the table from wsp_index.sch.

  4. Edit majic/wsp.mods file with the same changes made to wsp_schema.sch:
  5. Enter the following command using the command prompt:
    pdm_wspupd
    

    The pdm_wspupd script reads wsp_schema.sch and compares it with the wspcol table in the database, writing a line to the console for any differences. For example, see the following output:

    PDM_WSPUPD - Update wspcol table from wsp_schema.sch
    
    Reading wsp_schema.sch to for current DBMS information...
    
    Reading wspcol table for WSP schema information...
    
    String column zSalesOrg.description length changed from 350 to 400
    
    Column zSalesOrg.sym not found in wsp_schema.sch - deleting wspcol row
    
    pdm_wspupd found 1 WSP-maintained column(s) to update and 1 to delete. Please verify that your DBMS has been manually updated to correspond to wsp_schema.sch, then reply Y to update wspcol or anything else to cancel.
    
  6. Verify that the changes found by pdm_wspupd correspond exactly to the changes you made to wsp_schema.sch. If they match, type Y to confirm the changes.

    After you confirm the update, the script uses standard CA SDM utilities to update the wspcol table. Then, Schema Designer shows your changes.

  7. Stop the CA SDM servers.
  8. Using the appropriate utility for your DBMS, alter the DBMS definition of the columns you changed:

    Take care that the changes you make to the DBMS correspond exactly to the changes you made to wsp_schema.sch.

  9. Delete the wsp_schema.log file.
  10. Publish Schema Modifications.
  11. Start the CA SDM servers.