I would like to know how to prevent duplicate numbers in two columns

like name of column one is Tele other is Tele 2, if number in any columns it wouldnโ€™t allow , any ideas please ?
sorry for my English im trying to prevent duplicate like this
number in column Tele is 01117111388 if it is also in Column Tele 2 which is 01117111388
it would not be valid ? any ideas

Solved Solved
0 8 194
1 ACCEPTED SOLUTION

I wonder if this would do what you want done?

NOT(IN([_THIS], Clients[Tele 2]))

View solution in original post

8 REPLIES 8

Steve
Platinum 4
Platinum 4

Hello, i was there before i post the problem and typed the code and thought it works but actually it didnโ€™t would give me some tips ?

What did you try? In what way did it not do what you want?

NOT(IN([_THIS], SELECT(Users[User_Name], [UserID] <> [_ThisRow].[UserID])))

i used this one my sheet like this
NOT(IN([_THIS], SELECT(Clients [Tele 2], [Tele] <> [_ThisRow].[Tele])))
and it was accepted but the function didnโ€™t work, i need as the following
if the number in [Tele] = [Tele 2 ] make it invalid

Where did you enter these expression? I would expect them to be used in Valid If. The first for the User_Name column of the Users table, the second for the Tele 2 column of the Clients table.

Can you provide screenshots?




As attachments i added in Valid if for Tele as the code and it is acceptable as expression
But if i added any other number in Tele 2 and it is already in the column sheet in Tele it would not work

I wonder if this would do what you want done?

NOT(IN([_THIS], Clients[Tele 2]))

well Sir thank you so much, i got the idea from the type of coding and in Tele i did same code as you typed
then i went to Tele 2 and typed it as NOT(IN([_THIS], Clients[Tele]))
and it WORKED!!
you made my day thank you so much

Top Labels in this Space