I have a custom record type (let's call in TxGrp) ...
# suiteanalytics
j
I have a custom record type (let's call in TxGrp) that Transactions are attached to. Multiple Transactions can be attached to the same TxGrp. On Transaction, I also have two custom fields, let's call them start_date and end_date. I am looking for stats for the earliest/latest start_ and end_date for TxGrps. So far I have a Transaction search with five columns: - id of TxGrp (Group) - earliest start_date (Minimum) - latest start_date (Maximum) - earliest end_date (Minimum) - latest end_date (Maximum) What I'd also like is a column that shows the time span between the earliest start_date and latest_end_date, so I can sort my list by ones that have been going the longest. Is there a way to achieve this? I sort of want something like MAXIMUM ({custbody_end_date}) - MINIMUM({custbody_start_date})
g
Formula (Numeric) with
MAX({custbody_end_date}) - MIN({custbody_start_date})
👍🏼 1
I tried that on a simple transaction search just now and it works out with summary types of SUM, MINIMUM, and MAXIMUM.
k
I would suggest using a summary type of Min or Max
setting to SUM will break if you have more than 1 line on your transactions (it will add the difference for each line)
👍🏻 2
g
I've gotten into the habit of double checking math in saved searches just to be sure...especially with date math.
j
@KevinJ of Kansas I'm already filtering on main line = true