Setting up union fringe based on job

I am trying to figure out a way to have a union fringe calculate while only working on a certain job an employee works at and not their entire cheque. I tried using a formula and adding the job number but it does not work.