Hello All,
i have a table like a following one (of course, mine is bigger) that is coming from a query:
In the same file i have i have a cell, let's say B2. In B2 i'll insert all the time a different date.
What i'd like to do is to now, is obtain a new table where i'll have, for every single row (country):
Example:
If B2= 01/03/2020
my table will be:
For the VALUE column i was thinking to apply the following:
Anyway, this would be my approach. All the solutions to reach a layout like the second table will be really appreciated.
Thank you in advance for your help!
i have a table like a following one (of course, mine is bigger) that is coming from a query:
Countries | 01/01/2020 | 01/02/2020 | 01/03/2020 | 01/04/2020 | 01/05/2020 |
Argentina | 0 | 0 | 3000 | 2500 | 0 |
Australia | 0 | 1000 | 0 | 1500 | 3000 |
Austria | 1500 | 0 | 0 | 0 | 3000 |
Belgium | 0 | 0 | 0 | 2000 | 0 |
France | 1000 | 0 | 0 | 0 | 4000 |
Italy | 0 | 3000 | 0 | 0 | 0 |
In the same file i have i have a cell, let's say B2. In B2 i'll insert all the time a different date.
What i'd like to do is to now, is obtain a new table where i'll have, for every single row (country):
- First value>0 starting from the date greater or equal to the one in B2
- The date (column header) where the value >0 has been found
Example:
If B2= 01/03/2020
my table will be:
Country | Value (>0 for dates >=B2) | Date (only dates>= B2) |
Argentina | 3000 | 01/03/2020 |
Australia | 1500 | 01/04/2020 |
Austria | 3000 | 01/05/2020 |
Belgium | 2000 | 01/04/2020 |
France | 4000 | 01/05/2020 |
Italy | blank cause nothing>0 has been found for B2>=0 | blank cause nothing>0 has been found for B2>=0 |
For the VALUE column i was thinking to apply the following:
- IF formula to check if the date in the column header is >=B2, and if this is true then check if the value is >0. IF both conditions are true then provide me the value. IF one of the conditions is false check the next column header/value.
- check at first if a vale in the row is >0 and if this is true check if the date (column header) is >=B2. If both conditions provide me the column header, otherwise proceed with the next cell and repeat the operation
Anyway, this would be my approach. All the solutions to reach a layout like the second table will be really appreciated.
Thank you in advance for your help!