Create Check Constraint on M_QUESTIONS - Intergraph Smart Materials - Version 2020 (10.0) - Installation & Upgrade - Hexagon

Intergraph Smart Materials Installation (2020)

Language
English
Product
Intergraph Smart Materials
Subproduct
Classic
Search by Category
Installation & Upgrade
Smart Materials/Smart Reference Data Version
2020 (10.0)

If your database is on version 2020 SP1 (10.0.1) or above, you can skip this section.

  1. Launch SQL*Plus and connect as M_SYS.

  2. Perform the following commands:

    ALTER TABLE m_questions

       DROP CONSTRAINT qe_q_stage_chk

    /

    ALTER TABLE m_questions

    ADD (CONSTRAINT qe_q_stage_chk CHECK ((qualification_stage IS NULL AND level1 IN ( 'TE','CE') ) OR

    (qualification_stage IS NOT NULL AND level1 NOT IN ( 'TE','CE') )

    OR qualification_stage IS NULL))

    /