2 Replies Latest reply: Jan 30, 2013 6:11 AM by ILya Cyclone RSS

    Entity validation: record must be unique with some condition

    ILya Cyclone
      Hello,
      I need to validate an entity new row uniqueness against this entity rows with a condition.

      We have A, B, C columns. A user enters A and B values. C is calculated table field and sometimes is null.
      The new record must be unique against rows which have not null C attribute.

      A | B | C
      1 | 1 | 1
      1 | 2 | 1
      1 | 3 | -

      So validation must trigger an error when a user enters A=1,B=1 or A=1,B=2 but validation should pass when the user enters A=1,B=3 as soon as there are no A=1,B=3,C is not null rows.

      How to implement this?

      Thanks.
      ADF11R2