Forum Discussion
exodeexo
8 years agoNew Member
max date conditional
Hi guys!! I'd like to create a column (called "MAX_DATE") where I identify the max date in two specific process (PHTM & PHTS) per campaign. If these processes doesn't exist in the campaign, I'd l...
- 8 years ago
HI exodeexo
Please try this calculated column
New Column = MAXX( FILTER( 'Sequencer', 'Sequencer'[Process] IN {"PHTS","PHTM"} && 'Sequencer'[Campaign ID] = EARLIER('Sequencer'[Campaign ID]) ), 'Sequencer'[Start Sequence])
Phil_Seamark
8 years agoMicrosoft Employee
Cool, I nearly have it. Just one more question.
On that same campaign 136411, how come all the dates are the 13th, except for the last one which is the 14th of Oct?
exodeexo
8 years agoNew Member
Sorry Phil_Seamark. It was another mistake that I've modified. The expected result for campaign ID 136411 is 14/10/2015.
The correct table:
| Area | Process | Start Sequence | Campaign ID | MAX_DATE |
| WH | COD | 29/07/2015 | 155555 | null |
| WH | PREP | 30/07/2015 | 155555 | null |
| WH | PREP | 30/07/2015 | 135871 | null |
| PRODUCT | DESC_IT | 28/08/2015 | 135871 | null |
| WH | PREP | 30/07/2015 | 136411 | 14/10/2015 |
| PRODUCT | DESC_IT | 19/08/2015 | 136411 | 14/10/2015 |
| PHOTO | PHTM | 13/10/2015 | 136411 | 14/10/2015 |
| PHOTO | PHTS | 14/10/2015 | 136411 | 14/10/2015 |
| WH | PREP | 19/10/2015 | 127861 | 23/10/2015 |
| PHOTO | PHTM | 23/10/2015 | 127861 | 23/10/2015 |
| RETOUCH | BR24 | 14/10/2015 | 127861 | 23/10/2015 |
| RETOUCH | PROD | 14/10/2015 | 127861 | 23/10/2015 |
| PHOTO | PHTS | 13/10/2015 | 127861 | 23/10/2015 |
| PRODUCT | DESC_IT | 21/10/2015 | 127861 | 23/10/2015 |
| PRODUCT | UPDATA_IT | 15/10/2015 | 127861 | 23/10/2015 |
| PRODUCT | UPDATA_IT | 19/10/2015 | 127861 | 23/10/2015 |
| PHOTO | PHTM | 21/10/2015 | 127861 | 23/10/2015 |