Solved

Reduce duplicates, keeping uniques only

  • 26 September 2022
  • 3 replies
  • 2 views

Badge +7

I have a table containing ten lines (each one a street). Each street has a name and a zone value. But there are some duplicate records…

 

Street_name                       Zone_name

St James Street                  Zone B

High Street                         Zone B

High Street                         Zone B

High Street                         Zone D

High Street                         Zone D

Acacia Avenue                   Zone B

Acacia Avenue                   Zone B

Acacia Avenue                   Zone B

Acacia Avenue                   Zone C

Acacia Avenue                   Zone C

 

How would I reduce these down to unique records only. So, I’d end up with this…

 

Street_name                       Zone_name

St James Street                  Zone B

High Street                         Zone B

High Street                         Zone D

Acacia Avenue                   Zone B

Acacia Avenue                   Zone C

 

 

Thanks,

icon

Best answer by david_r 26 September 2022, 13:37

View original

3 replies

Userlevel 5
Badge +25

You could use a Sampler, set it to group by both attributes and then pass through only the first feature.

Userlevel 4

You can also consider the DuplicateFilter, set both Street_name and Zone_name as key attributes.

Badge +7

You can also consider the DuplicateFilter, set both Street_name and Zone_name as key attributes.

Thanks for that, David_R. It done the job. Regards, Stuart

Reply