Confrontare il contratto con quanto fatturato.
I lookup portano il prezzo medio fatturato e l’ultimo costo di ogni articolo. Conformità, aumento dei costi e margine sono formule sopra di essi, ricalcolate all’aggiornamento del contratto.
| Column | Formula |
|---|---|
| Invoiced Price | lookup(source="datasets", name="Invoice lines", result="Net Price", match_by=['Item Number':'Item Number'], filter_by=['Customer' == 'header.Customer', 'Invoice Date' >= 'header.effectiveDate'], agg="avg") |
| Compliance | if(abs('Invoiced Price' - 'Contract Price') > 0.01, "Off contract", "On contract") |
| Current Cost | lookup(source="datasets", name="Item costs", result="Unit Cost", match_by=['Item Number':'Item Number'], sort_by="-Effective Date", agg="first") |
| Cost Drift | ('Current Cost' - 'Cost at Signing') / 'Cost at Signing' |
| Margin % | ('Contract Price' - 'Current Cost') / 'Contract Price' |