
1. Re: Conditional arithmetic calculations
chris monger Sep 19, 2018 3:24 AM (in response to Mitchell Hensman)Hi Mitchell,
Am I right in thinking each column there is a different record? If so you can use if statements to get the correct dates.
datediff('day',
if [Segment] = 'Consumer' then 'Ship Date' end
,
if [Segment] = 'Corporate' then 'Ship Date' end
)

2. Re: Conditional arithmetic calculations
Chris McClellan Sep 19, 2018 3:24 AM (in response to Mitchell Hensman)You're probably after the DATEDIFF function : Date Functions
That will help you get the number of periods (you can choose) between the 2 dates.

3. Re: Conditional arithmetic calculations
meenu choudhary Sep 19, 2018 3:38 AM (in response to Mitchell Hensman)Hi Mitchell,
When you say you want to subtract "Consume ship date" to "Corporate ship date" , then on what ground you want to do so.
Like there are multiple ship date for both consumer and corporate ,so how are you gonna to choose which date to pic for subtraction.
It will be nice if you can provide your expected output.

4. Re: Conditional arithmetic calculations
Mitchell Hensman Sep 20, 2018 12:37 AM (in response to chris monger)Hi Chris,
They're actually in the same column though they used to be separate before I pivoted the fields.
Thanks,
Mitch

5. Re: Conditional arithmetic calculations
Mitchell Hensman Sep 20, 2018 12:45 AM (in response to meenu choudhary)Hi Meenu,
Sorry, I see I wasn't very clear there and looking at my expected output maybe what I'm asking for doesn't make a lot of sense. Below is an example of a 'unit' of my data and my expected output would be 187=11 days, so it would need another field at a higher level of detail to anchor to (in this case email address).
Thanks,
Mitch

6. Re: Conditional arithmetic calculations
chris monger Sep 21, 2018 3:40 AM (in response to Mitchell Hensman)Hi Mitch,
If I'm understanding you correctly my calc above should work.
If not can you provide an example workbook?

7. Re: Conditional arithmetic calculations
meenu choudhary Sep 21, 2018 7:28 AM (in response to Mitchell Hensman)