Validate range

Hi All,

I have one table with three fields Code, fromWeight and toWeight.

I want a validation in order to prevent overlapping of fromWeight and Toweight range.

Please Help.

Hello Moumita,

You want fromWeight should not be greater than Toweight validation or something else?

Regards

Arun

Hi,

I want to prevent the following case :

Code FromWeight toWeight
C001 1 10
C002 11 20
C003 2 5
C004 9 15

Hi Moumita,

u can write like this

public boolean validateWrite()

{

boolean ret;

if (this.Fromweight<this.to weight)

ret = super();

else

info(" ----error message---- ");

return ret;

}