ScheduleOperationDates

Schedule Operation Dates

Minor Business Rule

Object Name: B3100240

Parent DLL: CMFGBASE

Location: Client/Server

Language: C

1.Functional Description

1.1Purpose
This Business function is used to Schedule Operations in the WO routing and return WO start/requested 
date and Operation Start/Requested date depending on the Scheduling Type - Forward or Backward.


1.2Setup Notes and Prerequisites

• None.

1.3Special Logic

None.

2.Technical Specifications


2.4Processing 

a. Perform first call actions.
    If  Beginning Date = 0

If Schedule Type = 'F'

Beginning Date = WO Start Date.

Else

Beginning Date = WO Requested Date.

End.

Validate Beginning Date.

First Pass = '1'.

If Leadtime Type = 'F' and No of Operations <> 0

Read Manufacturing Constants table (F3009) using Branch/Plant IAMCU as the key. 

If row is found

Hours Per Day = IAWRHR.

Else

Hours per Day = 8.

End

End

    End.


b. Get Resource Units for the Beginning Date.

    If Schedule Type = 'B' and First Pass = '1'

Call Schedule Resource Units (B3100230) with 'Z' as Schedule Type and Begin Date as Input Date.

    Else

Call Schedule Resource Units (B3100230) with 'C' as Schedule Type and Begin Date as Input Date.

    Endif.    

    Load Beginning Date with Output Date and Current Hours with Output Current Hours.

    If First Pass = '1'

Balance Hours = Current Hours

    Else

If Previous Hours <> 0

Balance Hours = Balance Hours * Current Hours / Previous Hours

Endif

    Endif

    Previous Hours = Current Hours.


c. Calculate Required Hours.

    Initialise all work fields to zeros (Wk - Run Labor, Run Machine, Setup, Queue and Move hours).

    If Lead Time Type = 'F'

Wk Run Labor = Hours per day.

If No of Operations <> 0

If Prime Load Code = 'L'/'B'

Wk Run Labor = Wk Run Labor * No of  Employees.

Endif.

If Prime Load Code = 'M'/'C'

Wk Run Labor = Wk Run Labor * No of  Machines.

Endif.

Wk Run Labor = Wk Run Labor * Lead Time Level / No of Operations.

Endif.

    Endif.


    If Lead Time Type = 'V'

Wk Move Hours =  Input Move Hours.

Wk Queue Hours = Input Queue Hours.

If Prime Load Code = 'L'/'B'

Wk Run Labor = Input Run Hours

Endif.

If Prime Load Code = 'M'/'C'

Wk Run Machine = Input Machine Hours.

Endif.

If Prime Load Code = 'B'/'C'

Wk Setup Hours = Input Setup Hours.

Endif.

    Endif.


d. Back Schedule Dates.

    If Schedule Type = 'B'

If Lead Time Type = 'V'

Wk Overlap %  =  Previous Overlap %.

Previous Overlap %  =  Operation Overlap %.

If Wk Overlap % <> 0

Wk Required Hours = (Wk Run Labor + Wk Run Machine ) * Wk Ovelap % /100.

If (Balance Hours + Wk Required Hours) > Current Hours

Balance Hours = Current Hours - Balance Hours

If Wk Required Hours > Balance Hours

Wk Required Hours = Wk Required Hours - Balance Hours.

Call Schedule Resource Units (B3100230)

    with 'F' as Schedule Type, Begin Date as Input Date & Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif

Balance Hours = Current Hours - Balance Hours.

Previous Hours = Current Hours.

Else

Balance Hours = Balance Hours + Wk Required Hours.

Endif

Endif

Endif

If Balance Hours = 0

Call Schedule Resource Units (B3100230)  with 'Z' as Schedule Type, Begin Date as Input 

Date 

  and  0 as Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

 Endif

WO Requested Date = Beginning Date.

Wk Required Hours = Wk Move Hours. 


If  Wk Required Hours > Balance Hours

Wk Required Hours = Wk Required Hours - Balance Hours.

Call Schedule Resource Units (B3100230)  with 'B' as Schedule Type, Begin Date as Input 

Date 

 and Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif 

If Balance Hours = 0

Call Schedule Resource Units (B3100230)  with 'Z' as Schedule Type, Begin Date as Input 

Date

 and 0 as Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

Endif

Operation Requested Date = Beginning Date.

Wk Required Hours = Wk Run Machine + Wk Run Labour + WK Setup Hours.

If  Wk Required Hours > Balance Hours

Wk Required Hours = Wk Required Hours - Balance Hours

Call Schedule Resource Units (B3100230)  with 'B' as Schedule Type, Begin Date as Input 

Date 

   and Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif

Operation Start Date = Beginning Date.

If Balance Hours = 0

Call Schedule Resource Units (B3100230)  with 'Z' as Schedule Type, Begin Date as Input 

Date 

  and  0 as Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

 Endif

Wk Required Hours = Wk Queue Hours

If  Wk Required Hours > Balance Hours

Wk Required Hours = WK Required Hours - Balance Hours.

Call Schedule Resource Units (B3100230)  with 'B' as Schedule Type, Begin Date as Input 

Date 

   and Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif

WO Start Date = Beginning Date.

   Endif.


d. Forward Schedule Dates.

    If Schedule Type = 'F'

Wk Run Hours = Input Run Hours.

Input Run Hours = Wk Run Labour + Wk Run Machine.

Wk Overlap %  =  Operation Overlap %.

If Wk Overlap % <> 0

Wk Required Hours = Wk Run Hours * Wk Ovelap % /100.

If Wk Required Hours > Balance Hours 

Wk Required Hours = Wk Required Hours - Balance Hours.

Call Schedule Resource Units (B3100230)

    with 'B' as Schedule Type, Begin Date as Input Date & Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif

Endif

WO Start Date = Beginning Date.

Wk Required Hours = Wk Queue Hours. 

If  Wk Required Hours > Balance Hours

Wk Required Hours = Wk Required Hours - Balance Hours.

Call Schedule Resource Units (B3100230)  with 'F' as Schedule Type, Begin Date as Input 

Date 

 and Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif 

Operation Start Date = Beginning Date.

Wk Required Hours = Wk Run Machine + Wk Run Labour + WK Setup Hours.

If  Wk Required Hours > Balance Hours

Wk Required Hours = Wk Required Hours - Balance Hours

Call Schedule Resource Units (B3100230)  with 'F' as Schedule Type, Begin Date as Input 

Date 

   and Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif

Operation Requested Date = Beginning Date.

Wk Required Hours = Wk Move Hours

If  Wk Required Hours > Balance Hours

Wk Required Hours = WK Required Hours - Balance Hours.

Call Schedule Resource Units (B3100230)  with 'F' as Schedule Type, Begin Date as Input 

Date 

   and Wk Req Hours.

Load returned Balance Hours, Begin Date, Current Hours.

Previous Hours = Current Hours.

Else

Balance Hours = Balance Hours - Wk Required Hours.

Endif

WO Requested Date = Beginning Date.

   Endif.


If  there is any error in call to the function B3100230, return a '1' in the Error Code field 

otherwise return a '0'.


Data Structure

D3100240 - ScheduleOperationDates

Parameter NameData ItemData TypeReq/OptI/O/Both
cScheduleTypeWScharNONENONE

A user defined code to designate intra-pay period work schedules. This code can be used for reporting and to select employees to be 
included in a payroll run. For example:    A Monday through Friday    B Saturday through Wednesday    C Monday through Thursday (4 x 10 hrs)

szCostCenterMMCUcharNONENONE

A code that represents a high-level business unit. Use this code to refer to a branch or plant that might have departments or jobs, which 
represent lower-level business units, subordinate to it. For example:     o Branch/Plant (MMCU)     o Dept A (MCU)     o Dept B (MCU)     o Job 123 
(MCU) Business unit security is based on the higher-level business unit.

szWorkCenterMCUcharNONENONE

An alphanumeric code that identifies a separate entity within a business for which you want to track costs. For example, a business unit 
might be a warehouse location, job, project, work center, branch, or plant. You can assign a business unit to a document, entity, or person for 
purposes of responsibility reporting. For example, the system provides reports of open accounts payable and accounts receivable by 
business unit to track equipment by responsible department. Business unit security might prevent you from viewing information about business units 
for which you have no authority.

szUnitOfMeasureUMcharNONENONE

A user defined code (00/UM) that identifies the unit of measurement for an amount or quantity. For example, it can represent a barrel, box, 
cubic meter, liter, hour, and so on.

cLeadTimeTypeMRPPcharNONENONE

A code that determines whether the system uses fixed or variable leadtimes. This code works in conjunction with the value from either the 
Level Leadtime field or the Leadtime Per Unit field. Valid codes are:    F Fixed leadtime - The system calculates work order start dates using the 
value from the Leadtime Level field.    V Variable leadtime - The system calculates work order start dates using the value from the Leadtime 
Per Unit field.

mnLeadTimeLevelLTLVMATH_NUMERICNONENONE

A value that represents the leadtime for an item at its assigned level in the production process, as defined on Plant Manufacturing Data. 
The system uses this value to calculate the start dates for work orders using fixed leadtimes. Level leadtime is different for purchased and 
manufactured items: Purchased - The number of calendar days required for the item to arrive at your branch/plant after the supplier receives your 
purchase order. Manufactured - The number of workdays required to complete the fabrication or assembly of an item after all the 
components are available. You can enter level leadtime manually on Manufacturing Values Entry, or you can use the Leadtime Rollup program to 
calculate it. To calculate level leadtime using the Leadtime Rollup program, you must first enter a quantity in the Manufacturing Leadtime Quantity 
field in the Item Branch table (F4102).

cPrimeLoadCodePILCcharNONENONE

A code that determines if a work center is machine or labor intensive. The system also uses prime load codes in Resource Requirements 
Planning and Capacity Requirements Planning calculations to develop load profiles. Valid codes are:    L Run labor hours only    M Machine 
hours only    B Run labor plus setup labor hours    C Machine plus setup hours    O Other (will not generate resource units)

mnNumberOfEmployeesQMADMATH_NUMERICNONENONE

The normal number of employees in this work center. When you run the Work Center Resource Units Refresh program, the system 
multiplies this number by the Number of Work Hours Per Day from the Manufacturing Constants table (F3009) to generate the total gross labor hours 
available in the work center each day.

mnNumberOfMachinesNOMAMATH_NUMERICNONENONE

The normal number of machines in this work center. When you run the Work Center Resource Units Refresh program, this number is 
multiplied by the number of work hours per day from the Manufacturing Constants table (F3009) to generate the total gross machine hours available 
in the work center each day.

mnMoveHoursMOVDMATH_NUMERICNONENONE

The planned hours that are required to move the order from this operation to the next operation in the same work center. If the Routing 
Master values are blank, the system retrieves the default value from the work order routing. However, the system uses these values only for 
backscheduling variable leadtime items.

mnQueueHoursQUEDMATH_NUMERICNONENONE

The total hours that an order is expected to be in queue at work centers and moving between work centers. The system stores this value in 
the Item Branch table (F4102). You can calculate this value using the Leadtime Rollup program or you can enter it manually. When you run the 
Leadtime Rollup program, the system overrides manual entries and populates the table with calculated values.

mnRunLaborStandardRUNLMATH_NUMERICNONENONE

The standard hours of labor that you expect to incur in the normal production of this item. The run labor hours in the Routing Master table 
(F3003) are the total hours that it takes the specified crew size to complete the operation. The hours are multiplied by the crew size during shop 
floor release and product costing.

mnRunMachineHoursRUNMMATH_NUMERICNONENONE

The standard machine hours that you expect to incur in the normal production of this item.

mnSetupHoursSETLMATH_NUMERICNONENONE

The standard setup hours that you expect to incur in the normal completion of this item. This value is not affected by crew size.

mnHoursPerDayWRHRMATH_NUMERICNONENONE

The number of work hours that the manufacturing plant operates per day.

mnOperationOverlapPOVRMATH_NUMERICNONENONE

A number that indicates the percentage that successive operations can overlap. The actual overlap percentage entered for the operation 
sequence is the percent by which that operation overlaps the prior operation. For example, if you enter 80%, this indicates that work can begin 
on the overlapped operation when 20% of the prior operation is completed. Notes:    1.   Overlapping has no effect on move and queue 
calculations.    2.   The percent entered must be less than or equal to 100%. Enter percents as whole numbers:  5% as 5.00

mnPrevOperOverlapPOVRMATH_NUMERICNONENONE

A number that indicates the percentage that successive operations can overlap. The actual overlap percentage entered for the operation 
sequence is the percent by which that operation overlaps the prior operation. For example, if you enter 80%, this indicates that work can begin 
on the overlapped operation when 20% of the prior operation is completed. Notes:    1.   Overlapping has no effect on move and queue 
calculations.    2.   The percent entered must be less than or equal to 100%. Enter percents as whole numbers:  5% as 5.00

mnHoursBalanceWRHRMATH_NUMERICNONENONE

The number of work hours that the manufacturing plant operates per day.

mnHoursPreviousWRHRMATH_NUMERICNONENONE

The number of work hours that the manufacturing plant operates per day.

mnHoursRunWRHRMATH_NUMERICNONENONE

The number of work hours that the manufacturing plant operates per day.

mnNoOfOperationsOPSQMATH_NUMERICNONENONE

A number used to indicate an order of succession. In routing instructions, a number that sequences the fabrication or assembly steps in the 
manufacture of an item. You can track costs and charge time by operation. In bills of material, a number that designates the routing step in the 
fabrication or assembly process that requires a specified component part. You define the operation sequence after you create the routing 
instructions for the item. The Shop Floor Management system uses this number in the backflush/preflush by operation process. In engineering 
change orders, a number that sequences the assembly steps for the engineering change. For repetitive manufacturing, a number that 
identifies the sequence in which an item is scheduled to be produced. Skip To fields allow you to enter an operation sequence that you want to begin 
the display of information. You can use decimals to add steps between existing steps. For example, use 12.5 to add a step between steps 
12 and 13.

jdWOStartDateSTRTJDEDATENONENONE

The start date for the order. You can enter this date manually, or have the system calculate it using a backscheduling routine. The routine 
starts with the required date and offsets the total leadtime to calculate the appropriate start date.

jdWOReqDateDRQJJDEDATENONENONE

The date that an item is scheduled to arrive or that an action is scheduled for completion.

jdOperStartDateSTRTJDEDATENONENONE

The start date for the order. You can enter this date manually, or have the system calculate it using a backscheduling routine. The routine 
starts with the required date and offsets the total leadtime to calculate the appropriate start date.

jdOperReqDateDRQJJDEDATENONENONE

The date that an item is scheduled to arrive or that an action is scheduled for completion.

cErrorcodeERRCcharNONENONE

This error code indicates if any errors occurred during the creation of the Trip Document Detail (F4914) records by the Delivery Document 
Set Server program (XT4914).

jdBeginningDateDRQJJDEDATENONENONE

The date that an item is scheduled to arrive or that an action is scheduled for completion.

cQueueHrsSchedulingMethodEV01charOPTNONE

An option that specifies the type of processing for an event.

jdPrevOperReqDateDRQJJDEDATEOPTNONE

The date that an item is scheduled to arrive or that an action is scheduled for completion.

mnWorkCenterShiftHoursWRHRMATH_NUMERICOPTNONE

The number of work hours that the manufacturing plant operates per day.

cPOOverrideNoOfEmpEV01charOPTNONE

An option that specifies the type of processing for an event.

mnPreviousOperStepHoursWRHRMATH_NUMERICOPTNONE

The number of work hours that the manufacturing plant operates per day.

Related Functions

B3100230 Schedule Resource Units

Related Tables

F3009 Job Shop Manufacturing Constants