Forum Discussion
OSCARJD
Aug 31, 2022Copper Contributor
Power Query for EXCEL MAX & MIN
Hello, I hope you can help me out to solve this in power query for EXCEL. I have two tables "TABLA BASE ACTUAL" and "TABLA CLASIFICACION". In the second one, I have a classification "Clasificación" that is individual for each obligation number "Obligación". However in the first one ,I should consolidate de maximum and the minimum "Classification" based on the ID. It means each ID should have different obligations but I have to consolidate or have the max and the min of the "Clasificación" for each individual. I have attached current situation and the expected outcome. Thanks
| TABLA BASE "CURRENT SITUATION" | ||
| Obligación | ID | Clasificación |
| 3245 | 156789 | 1 |
| 2156 | 76190 | 2 |
| 9623 | 15322 | 3 |
| 9140 | 156789 | 2 |
| 3523 | 156789 | 4 |
| 7860 | 19007 | 5 |
| 6412 | 76190 | 1 |
| 2367 | 19875 | 3 |
| 1938 | 36206 | 0 |
| 1623 | 12489 | 0 |
| TABLA CLASIFICACION | |
| Obligación | Clasificación |
| 9623 | 3 |
| 9140 | 2 |
| 7860 | 5 |
| 6412 | 1 |
| 3523 | 4 |
| 3245 | 1 |
| 2367 | 3 |
| 2156 | 2 |
| TABLA BASE "EXPECTED OUTCOME" | ||||
| Obligación | ID | Clasificación | Max | Min |
| 3245 | 156789 | 4 | 4 | 1 |
| 2156 | 76190 | 2 | 2 | 1 |
| 9623 | 15322 | 3 | 3 | 3 |
| 9140 | 156789 | 4 | 4 | 1 |
| 3523 | 156789 | 4 | 4 | 1 |
| 7860 | 19007 | 5 | 5 | 5 |
| 6412 | 76190 | 2 | 2 | 1 |
| 2367 | 19875 | 3 | 3 | 3 |
| 1938 | 36206 | 0 | 0 | 0 |
| 1623 | 12489 | 0 | 0 | 0 |
1 Reply
- Riny_van_EekelenPlatinum Contributor