Hi Community,
Suppose I have the following sample data:
| State | Code |
| Alabama | AL |
| Alaska | AK |
| Arizona | AL |
| Arkansas | AR |
| American Samoa | AS |
| California | CA |
| Colorado | CO |
| Connecticut | CA |
| Delaware | DE |
| District of Columbia | CA |
I want to ensure each State has its own unique Code. I would like to show an error message if this isn't the case. Using the above data, two error message would be shown like:
Error: the following states can't have the same code: Alabama, Arizona
Error: the following states can't have the same code: California, Connecticut, District of Columbia
My thinking is to create a table with the codes that have duplicates, and a second column with the corresponding states. For example:
| Code | States_Concat |
| AL | Alabama, Arizona |
| CA | California, Connecticut, District of Columbia |
And then use the Message tool on above table. Any idea how to create above table? Also happy to see different approaches of course.
Thanks.