I want to do a validation check of the Trial Balance which is being loaded to check if it is tallying or not(sum is netting to 0). If the sum of the TB is 0 then it should proceed to export or stop at validate if the sum is not 0. Can someone help me with the script and what parameters we need to define inside it?
Validation step only checks mappings. The trial balance report you want will be run in Check Step. You will need to define the validation rules to check the TB and then attach it to the location.
But irrespective of the TB balance value, Export step will run and load the data even if the Check report fails as this step will take place after Export.
There are various options you can use e.g. Create logic accounts to do the accumulation of totals then in the AftValidate script do a check on them, or do a SQL call to do the totalling. In the AftValidate script investigate the lngProcState variable - have a look in the FDM API guide you should be able to work it out from the examples and information provided.