How to Calculate Salesman Comission (Total sales)

How can we calculate performance of the sales man.
In our existing ERP Software, We used to put sales man nae in very order, and at the end of the year, we can sort out (total) how much the sales man did the sale. How can we do it?

You could create a Custom Field on the Sales Invoice and put in their name as you currently do
You could use Tracking Codes, their Name could be the code.
If each Customer is only serviced by one salesman then the Customer Code could be used - if the salesmen name is Billy Kid then Customer code could be BK???