I have a list of values in the column that I need to remove or to keep based on the following criteria:
If the same id have the following types (on the same ID): 1000, 1100, 1200, 1300 and any other types such as 700, 800, 900 and etc. I need to remove the these types (1000, 1100, 1200, 1300)
But if the ID has only types: 1000, 1100, 1200, 1300 and no other types then keep them
Source
ID | TYPE
40208001 | 700
40208001 | 1100
40209017 | 900
40209017 | 800
40209017 | 910
40209017 | 1200
40210494 | 1100
40210494 | 1000
40210494 | 1200
40210551 | 400
40210551 | 1200
40210767 | 1200
40210767 | 800
40211724 | 1300
40211724 | 900
40211724 | 500
WHAT I WANT:
ID | TYPE
40208001 | 700
40208001 |
40209017 | 900
40209017 | 800
40209017 | 910
40209017 |
40210494 | 1100
40210494 | 1000
40210494 | 1200
40210551 | 400
40210551 |
40210767 |
40210767 | 800
40211724 |
40211724 | 900
40211724 | 500