Skip to Main Content

SQL Developer Data Modeler

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

ODM changed text of constraints after save and reopen model - remove all newlines from check text

user466917Dec 28 2024 — edited Dec 31 2024

ODM = Oracle data modeler.

  1. Next scenario tested on Oracle Data Modeler 24.3.1 and 24.3.0
  2. Create new model - menu File - Close All
  3. Create one domain with multiline CC for example - Tools - Domain Administration- Add

  1. Save as new named model.
  2. Restart ODM + open same model
  3. Go to domain definition Tools - Domain Administration - select domain and press Check constraint:

all newlines were removed.

The same situation is if define manually CC on column in table and the worse is that after Synchronize Model With Data Dictionary all CC are the same as in DB and after reopening model there are differences between model and data dictionary.
Another interesting fact - multiline checks on table are OK - don't change after save and reopen model.

Definition in domain file testCheckMultilineDomain\domains\project_domain.xml after first save.

<checkConstraint>
<implementationDef dbType="Generic Constraint" definition="DECODE(%column%, TRANSLATE(%column%, CHR(9)||CHR(10)||CHR(13),&apos;XXX&apos;),1,0)=1
  AND DECODE(%column%, RTRIM(LTRIM(%column%)),1,0)=1   
  AND NVL(INSTR(%column%,CHR(32)||CHR(32)),0)=0"/>
</checkConstraint>

Definition in domain file testCheckMultilineDomain\domains\project_domain.xml after reopening and save

<checkConstraint>
<implementationDef dbType="Generic Constraint" definition="DECODE(%column%, TRANSLATE(%column%, CHR(9)||CHR(10)||CHR(13),&apos;XXX&apos;),1,0)=1   AND DECODE(%column%, RTRIM(LTRIM(%column%)),1,0)=1      AND NVL(INSTR(%column%,CHR(32)||CHR(32)),0)=0"/>
</checkConstraint>

I tried change New line separator (I'm on Windows) - Tools - Preferences - Data modeler - Enviroment - Line terminator - no effect.

Can anybody help me with explanation of my mistake or know any workaround ??

Comments

Processing

Post Details

Added on Dec 28 2024
2 comments
157 views