unique entries in a variant

Is there a way to leverage variants to deal with unique data? Example: If I pull the dept names for a list of people, but only only want to store each dept name once. Currently my code sorts the data and does compares of the current Dept  to the last one used.
Who is Participating?
CRAKConnect With a Mentor Commented:
Ehhh Sjef, is there anything wrong with ArrayUnique(sourceArray [,compMethod ])?
(nothing personal, buddy!)
what language are you using? can you just do @unique(deptnames) ?
Sjef BosmanConnect With a Mentor Groupware ConsultantCommented:
Or, 100% equivalent to theprevious post, but in LotusScript:
      v= Eval("@Unique(deptnames)",doc)
      v= Eval(|@Unique("| & (Join(deptnames,|":"|) & |")|)
depending on where the values are.
Sjef BosmanGroupware ConsultantCommented:
Ehm, well, now, right, oooops... Just wanted to show that "clever" things can be done using Eval()... Not so clever after all, apparently...

Is there a backdoor in this room??
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.