cancel
Showing results for
Did you mean:
cancel
Showing results for
Did you mean:

14-Alexandrite

How to use valid range constraint for string??

Hi All,

I would like to know, how to use "valid range" constraint for String attribute.

I've defined: From aa To bb.

As a result, I'm able to create business object that has 'ac' as a value of attribute, but 'ca' isn't acceptable.

Could somebody explain it in simple words?

Krzysztof
1 ACCEPTED SOLUTION

Accepted Solutions
21-Topaz I
(To:Gucio)

Hi @Gucio

it is similar to numbers.

range from 11 to 22  is not just 11, 12, 21, 22 but it is 11-19 and 20 - 22

an alphabet range is a-z for one position of a character. same as a number 0-9.

Is it more clear?

With range "aaa - ccc" you can still write "cbz" because it is in specific range.

PetrH

4 REPLIES 4
21-Topaz I
(To:Gucio)

Hi @Gucio

What do you expect?

Your result definition is from aa to az and from ba to bb

if you expect a range aa, ab, ba, bc then you should use different constraint for example the Legal value list

Hope this help

PetrH

14-Alexandrite
(To:HelesicPetr)

Hi Petr,

I'm still not able to catch it.

I was expected to achieve result similar to your example with Legal Value.

I was thought, that giving boundaries starting from 'aa' and finishing at 'bb' will allow user to fill one of four options: 'aa' or 'ab' or 'ba' or bb'. Why 'az' and 'ba' did you mention as result?
Going deeper, making valid range form 'aaa' to 'ccc' in my mind should allow typing 'aaa' or 'aab' ..... up to 'ccc'.

Would you be so kind as to clarify the answer?

Krzysztof
21-Topaz I
(To:Gucio)

Hi @Gucio

it is similar to numbers.

range from 11 to 22  is not just 11, 12, 21, 22 but it is 11-19 and 20 - 22

an alphabet range is a-z for one position of a character. same as a number 0-9.

Is it more clear?

With range "aaa - ccc" you can still write "cbz" because it is in specific range.

PetrH

14-Alexandrite
(To:HelesicPetr)

@Petr

now it is clear 🙂