Hi;
Just like the sample in Aware:
If EXISTS SystemUser WHERE (SystemUser.LoginName = ThisSystemUser.LoginName) Then REPORT ERROR 'User with this name already exists'
I'm trying the same with Product Object, and as soon as I press Save on form, I get error that Product already exist and rules blocks the object to be saved.
I had put in
If EXISTS Product WHERE (Product.Name=ThisProduct.Name AND Product.ID=ThisProduct.ID) then REPORT ERROR 'Product exists'
Even when there is no object, it returns True, which it thinks there is one already in Database.
What am doing different or wrong?
I can't find any other sample that uses Uniqueness except the above with User.
Thanks!