I have an issue with a string variable which unfortunately contains several values(Phone numbers) with ; as the delimiter.
When the string contains several unique numbers it will list them accordingly which is fine, but when the string contains a phone number twice, it will list the number twice too.
I want to remove duplicate phone numbers.
Example: PHONE_NUMBER_LIST = 12345678; 12345678. In this case i want the output to be 12345678
PHONE_NUMBER_LIST = 12345678; 12345678
%%[
SET @rows = BuildRowsetFromString(@PHONE_NUMBER_LIST,";")
for @i = 1 to rowCount(@rows) do
SET @row = row(@rows, @i)
SET @phone_list = field(@row,1)
]%%
<br>%%=v(@phone_list)=%%
%%[
next @i ]%%
%%[ else ]%%
%%[ endif ]%%
The actual output is:
12345678
12345678
What I want is:
12345678