sa39-00

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
sa39-00 [2015/08/07 17:06] Justin Willeysa39-00 [2017/12/01 16:35] (current) – external edit 127.0.0.1
Line 52: Line 52:
     or @DivisionName not in( 'Division1','Division4'     or @DivisionName not in( 'Division1','Division4'
     or @USERID not in( 'TestUser1','TestUser2')     or @USERID not in( 'TestUser1','TestUser2')
-    -- if any of the above true then employee base rate does not apply+    -- if any of the above true then Temp base rate does not apply
   then   then
     return BaseRate     return BaseRate
Line 61: Line 61:
     when @PayrollFlag = 'THLF' then return round(@TempBaseRate*1.5,2) --Time + one half     when @PayrollFlag = 'THLF' then return round(@TempBaseRate*1.5,2) --Time + one half
     when @PayrollFlag = 'TQTR' then return round(@TempBaseRate*1.25,2) --Time + one quarter     when @PayrollFlag = 'TQTR' then return round(@TempBaseRate*1.25,2) --Time + one quarter
-    when @PayrollFlag = 'EVE' then return round(@TempBaseRate+isnull(@TempEveningRate,0),2) --Employees evening uplift  +    when @PayrollFlag = 'EVE' then return round(@TempBaseRate+isnull(@TempEveningRate,0),2) --Temps evening uplift  
-    when @PayrollFlag = 'NIGHT' then return round(@TempBaseRate+isnull(@TempWeekEndRate,0),2) --Employees weekend uplift+    when @PayrollFlag = 'NIGHT' then return round(@TempBaseRate+isnull(@TempWeekEndRate,0),2) --Temps weekend uplift
     when @PayrollFlag in( 'EXP1','EXP2','HP') then return BaseRate --Expenses and Holiday Pay etc excluded so use placement or vacancy rate     when @PayrollFlag in( 'EXP1','EXP2','HP') then return BaseRate --Expenses and Holiday Pay etc excluded so use placement or vacancy rate
     else     else
-      return round(@TempBaseRate,2) --Employee base rate applies+      return round(@TempBaseRate,2) --Temp base rate applies
     end case     end case
   end if   end if
 end end
 </code> </code>
 +
 +Note the way the function exits immediately for **charge** rates to minimise processing, as the scheme does not effect charge rates. Also note how in this example the calculations are only made for certain test users to facilitate testing of the scheme. This clause //or @USERID not in( 'TestUser1','TestUser2')// would be removed for go live. 
  • sa39-00.1438967169.txt.gz
  • Last modified: 2017/11/16 21:57
  • (external edit)