The parts of this formula are all valid. However, when put together, the message "INVALID FORMULA" is displayed. The schema and table names have been sanitized, but the table is an aggregated count by date of some other data. I have tried variants without success.
(if( table.Dt1 = $currentDate, table.Count, 0 ) / (sum( if( between( table.Dt1, lookup( Date_Time.Business_Days.business_3_days_ago_date, Date_Time.Business_Days.date, $currentDate ), date( $businessDayAgo ) ), table.Count, 0 ) ) / 3)) - 1