1
votes

I'm writing a Netsuite saved search for Sales Orders, and I'd like to know the difference between the maximum date for an ordered item and the minimum date for an ordered item.

In specific, I need to calculate the number of days between when an item was first and last ordered.

I can easily display the Maximum (and minimum) date an item was ordered using the "group" and summary columns, but not the difference between those two dates. Is this possible?

1

1 Answers

3
votes

Group by Item, then create a Formula(Numeric) with Summary type Maximum (or Minimum - it makes no difference in this case) and use the following formula:

max({trandate}) - min({trandate})