Hello community!!!
We are trying to solve the below problem.
Our system can export data like below
What we need to build from the above table is to keep only one row per hotel, room code with min & max dates.
So for example for the first 2 rows we need to keep only one like the below
We would be very satisfied if we could get a final result like the below, so we could filter the non blank cell in last column (Date Till) and extract what we need.
Always keeping in mind that columns
Hotel Code - TK
Contracting Group
Room Code
must be accumulated into the procedure
I hope its clear enough for you to understand the needed result.
Thank you in advance
We are trying to solve the below problem.
Our system can export data like below
Hotel Tourism Destination Code | Hotel Name | Hotel Code - TK | Contracting Group | Room Code | Room Description | Date |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 04/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 05/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 21/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 22/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 23/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 24/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 25/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 26/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 27/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 28/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 29/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 30/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 04/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 05/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 21/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 22/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 23/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 24/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 25/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 26/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 27/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 28/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 29/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 30/05/2024 |
What we need to build from the above table is to keep only one row per hotel, room code with min & max dates.
So for example for the first 2 rows we need to keep only one like the below
Hotel Tourism Destination Code | Hotel Name | Hotel Code - TK | Contracting Group | Room Code | Room Description | Date From | Date Till |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 04/05/2024 | 05/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 21/05/2024 | 30/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 04/05/2024 | 05/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 21/05/2024 | 30/05/2024 |
We would be very satisfied if we could get a final result like the below, so we could filter the non blank cell in last column (Date Till) and extract what we need.
Always keeping in mind that columns
Hotel Code - TK
Contracting Group
Room Code
must be accumulated into the procedure
Hotel Tourism Destination Code | Hotel Name | Hotel Code - TK | Contracting Group | Room Code | Travel Kiss Room Description | Date | Date Till |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 04/05/2024 | 05/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 05/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 21/05/2024 | 30/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 22/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 23/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 24/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 25/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 26/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 27/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 28/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 29/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00GV00 | Standard Bungalow (GardenView) | 30/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 04/05/2024 | 05/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 05/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 21/05/2024 | 30/05/2024 |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 22/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 23/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 24/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 25/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 26/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 27/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 28/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 29/05/2024 | |
Dest | Hotel name | AMTSGR0MGK | OWN2 | BUSD00SV00 | Standard Bungalow (SeaView) | 30/05/2024 |
I hope its clear enough for you to understand the needed result.
Thank you in advance