$ 0 0 My query copies line item to line item. If you want the Total Amount Due on the document level, then you will want SELECT $[$12.0.Number]