基于列值过滤结果集:按NodeId筛选ProcessingSystem的规则实现
数据集过滤处理方案
原始数据集
| NodeId | NodePath | ProcessingSystem |
|---|---|---|
| 55315710 | ALL->Test->Sub | test1 |
| 55315710 | ALL->Test->Sub | test2 |
| 109389601 | ALL->Path2->Sub | test2 |
| 109389601 | ALL->Path2->Sub | test1 |
| 99315710 | ALL->Test->Sub | test1 |
过滤规则
- 同一
NodeId下,若存在ProcessingSystem为test1的行,仅保留该行 - 同一
NodeId下所有行的ProcessingSystem均为test2时,保留第一行(注:同一NodeId对应的NodePath始终相同)
过滤后结果
| NodeId | NodePath | ProcessingSystem |
|---|---|---|
| 55315710 | ALL->Test->Sub | test1 |
| 109389601 | ALL->Path2->Sub | test1 |
| 99315710 | ALL->Test->Sub | test1 |
内容的提问来源于stack exchange,提问作者user15682658
相关产品推荐
相关产品推荐

