Skip to main content

I am trying to use a Validation Rule to assure that the user does not enter a value in a field that is already used in another

list in the same site.  In the Validation Rule for the SiteURL field, I have:

 

not(isNullOrEmpty(lookup("Site Collection Portfolio","Site URL",{ItemProperty:SiteURLFull},"ID")))
Result: NEVER evaluates to true.  I tried values that are and are not in the lookup list.

 

My thinking was that if the lookup function returned a value for ID, then the validation fails (user is not allowed to save), and

if the lookup function failed to return a value for ID, it would be null or empty, and the validation passes (user is allowed to

save).

 

A couple of questions:
(1) Should the "List Title" (parameter 1 of the lookup function) be Display Name or Internal Name?  I think it is Display Name

because I receved an error when I tried Internal Name, but I am not sure.
(2) Should the "Column To Filter On" (parameter 2 of the lookup function) be Display Name or Internal Name?
(3) Will this work if the "Value To Filter On" (parameter 3 of the lookup function) is a Calculated Column?  I also tried it as

two concatenated Single Line of Text fields, and got the same results.

 

Any help is appreciated - thanks!

 

(Nintex Forms 2.4.1.0)

1) "List Title" should be Display Name

2) "Column to Filter on" should be Display Name

3) Calculated Column will not work as "Value To Filter On" because calculated column value get calculated on posting value , validation is taking place before posting.

 

You can try this

not(isNullOrEmpty(lookup("Site Collection Portfolio","Site Url",Ctrl_String1+Ctrl_String2,"ID")))


YES - perfect - thanks, Rohan - I appreciate the reply and will mark this correct!


Reply