DataTables("订单表").DataCols("包号统计").Expression = ""DataTables("订单表").load()
For Each dr As DataRow In DataTables("订单表").DataRows
ids = ids & "," & "'" & dr("订单号") & "'"
Next
DataTables("包号子表").LoadFilter = "[订单号] In (" & ids & ")"
DataTables("记录子表").LoadFilter = "[订单号] In (" & ids & ")"
DataTables("颜色子表").LoadFilter = "[订单号] In (" & ids & ")"
DataTables("包号子表").Load()
DataTables("记录子表").Load()
DataTables("颜色子表").Load()
DataTables("订单表").DataCols("包号统计").Expression = "Sum((child.包号关联).包号)"