I have the following dataframe:
| Material | End Date | Start Date | Qty |
|---|---|---|---|
| A | 10-Dec | 10-Dec | 4 |
| B | 13-Dec | 14-Dec | 2 |
| C | 14-Dec | 16-Dec | 3 |
| D | 15-Dec | 15-Dec | 0 |
| E | 16-Dec | 17-Dec | 1 |
I want to unpivot this dataframe in a way that gives me the output: Here where the end date and start date is same, should not be printed twice.
| Material | Date | Qty |
|---|---|---|
| A | 10-Dec | 4 |
| B | 13-Dec | 2 |
| B | 14-Dec | 2 |
| C | 14-Dec | 3 |
| C | 15-Dec | 3 |
| C | 16-Dec | 3 |
| D | 15-Dec | 0 |
| E | 16-Dec | 1 |
| E | 17-Dec | 1 |
Can I get the code for this ?