CalculateRemainingPayPeriodInYr

Calculate Remaining Pay Period In The Year

Minor Business Rule

Object Name: N0800061

Parent DLL: CHRM

Location: Client/Server

Language: NER

Functional Description

Purpose

This program determines remaining pay periods in the year bassed on a date and Pay Frequency.

Setup Notes and Prerequisites


Special Logic

If Perameter PayFrequency is not Blank then run this program otherwise Pay Period Count is set to '1' 

 


Technical Specification

RsaYear = year from perameter jdDateEffectiveRates
Fetch number of pay periods in String format using 'Get UDC Description'

If Fetch is not successful Number of pay periods defaults to '1'

If perameter PayCycleCode is not equal to  

Fetch PayPeriodNumber from F069066

Loop until highest  and lowest Pay Period for the year has been found

CanadaPayPeriod is set equal to highest (NumberPayPeriods -1)

If highest Number Pay Periods accurate then 

perameter PeriodCount = (Highest NumberPayPeriods -Lowest NumberPayPeriods) +1

Else PayCycleNotFoundflag = "1"

If no record found, either pay cycle code is invalid or the payroll master pay cycle is not setup for 

the effective date

If PayCycleNotFoundflag is equal to "1" Or Perameter  PayCycleCode is equal to  

Search for pay cycle code in f069066 that has the same number of pay periods as pay frequency, if 

found 

Loop until lowest Pay Period for the year has been found

PeriodCount = (highest NumberPayPeriods- lowest NumberPayPeriods)+1

If no record found, and pay frequency not supplied, default '1' to remaining




^

Data Structure

D0800061 - Calculate Remaining Pay Period In The Year

Parameter NameData ItemData TypeReq/OptI/O/Both
szPayCycleCodePCCDcharOPTINPUT

A code that identifies the values for a master payroll cycle.

jdDateEffectiveRatesEFTJDEDATEOPTINPUT

The date that identifies when a date is first valid. The effective date is used generically. It can be a lease effective date, a price or cost 
effective date, a currency effective date, a tax rate effective date, or whatever is appropriate.

mnPeriodCountPPCTMATH_NUMERICOPTOUTPUT

The number of periods for the specified process.

cPayFrequencyPFRQcharOPTINPUT

A user defined code (07/PF) that indicates how often an employee is paid. Valid codes are: B Biweekly   W Weekly   S Semimonthly  
M Monthly   A Annually   C European Annualized  The system uses the value in the Description-2 field on user defined codes to calculate the amount per 
pay period for a salaried employee.

Related Functions

None

Related Tables

None