Custom script that calculating total, at the sales order doctype


I need to add more table item at the SalesOrder Doctype, but the total only calculating item just from default items table,
How to make total calculate every table that I created?

sorry for my bad English.

To calculate total for all table you need to write the custom script for Sales Order.

Please help with query