MAC-PAC Homecontact ussupport login 
Documentation > MAC-PAC Technical Library > Distribution > Order Processing > Programs > Sales Order Inquiry - Purpose > Sales Order Inquiry - Calculations

Sales Order Inquiry - Calculations

OP800E

A.   Housekeeping

1.   See the Common Processing Routines - Housekeeping section of this manual for a general discussion of this subroutine.  Processing specific to this program is described below.

2.   The Company Name is retrieved from the System Control file (CT100M).

3.   The following information is retrieved from the Reference file (REFERP):

a.   Applications installed (category 012).

b.   Date format (category 049).

c.   Order Processing system defaults record (category 412). Three flags on this record are checked.  If the multiple currency environment flag is on, an indicator is set to display Currency Code and Exchange Rate.  If the value added tax or Goods and Services tax environment flag is on, an indicator is set to display VAT or GST Code and home/export flag.  If the display cost information flag is on, an indicator is set to display Unit Cost and Gross Margin Percent.

4.   The following information is loaded to an array from the Reference file.

·     Order Type (category 401).

·     Hold Code (category 402).

·     Order Status (category 403).

·     Part Type (category 405).

·     Home/export flag (category 406).

·     Currency Codes (category D84)

5.   If this program was entered via fast path from the Sales Order Maintenance program (OP100E), the Fast Path Code is checked.  The Display Status field (DSPSTS) is set to direct screen processing.

a.   If the Fast Path Screen Code is blank, the Display Status is set to DSP, and the Function Select screen is displayed.

b.   If the Fast Path Screen Code is C (Customer), the display status is set to DSP, The Customer Number, Customer Ship-to Suffix, and Orders by Customer fields are filled with the values that were passed from the Sales Order Maintenance program (OP100E).  The Function Select screen is displayed.

c.   If the Fast Path Screen Code is S (Sales Order), the Display Status is set to blanks.  The Selected Order, Order Number, and Release Number fields are filled with the values that were passed from the Sales Order Maintenance program.  These fields are validated.  See the Order Processing User Manual for validation rules.

(1)  If there are no errors, the Sales Order Inquiry Recap Screen (OP800S06) is displayed. 

(2)  If there are errors, the Function Select screen is displayed.  The field in error is highlighted and an error message is displayed.

B.   Function Select

1.   All fields are validated.  See the Sales Order Inquiry in the Screens section of the Order Processing User Manual for validation rules.

2.   The following inquiries can be selected:

a.   Selected Order:  If the Order Number, Release Number, and Line Number have been entered, the line detail screen is displayed.  If the Line Number has not been entered, the recap screen is displayed.

b.   Orders By Customer Number:  The Orders By Customer Screen (OP800S02) is displayed with sales orders that match the user-specified criteria.

c.   Orders By Part Number:  The Orders By Part Screen (OP800S03) is displayed with sales orders that match the user-specified criteria.

C.   Orders by Customer

1.   This screen displays sales orders by Customer Number, one page at a time.  Records are retrieved from the logical Sales Orders by Customer Number file (OP100ML1).  Only those records that match the user-specified values are displayed.

2.   The next page of customer orders can be loaded and displayed by using the ROLL key.

3.   If summary information for a specific order has been requested, the recap screen is displayed for that order.  If no order has been selected, the Function Select screen is redisplayed.

D.   Orders by Part

1.   This screen displays sales orders by Part Number, one page at a time.  Records are retrieved from the logical Sales Orders by Part Number file (OP100ML2).  Only those records that match the user-specified values are displayed.

2.   The next page of orders can be loaded and displayed by using the ROLL key.

3.   If detailed information for a specific order line has been requested, the line detail screen is displayed for that line.  If no order line has been selected, the Function Select screen is redisplayed.

E.   Header

1.   This screen provides header information for the specified sales order.  Records are retrieved from the Sales Order Header file (OP100M1).

2.   If the Comments field contains Y, the comments screen is displayed.  If the Comments field is blank, the previous screen is displayed.

3.   Command keys can be used to display order by customer information as well as direct distribution information.

F.   Line Detail

1.   This screen provides line detail information for the specified sales order.  Records are retrieved from the Sales Order Line Detail file (OP100M2).

2.   If there are any more lines for the Order Number and Release Number, they are displayed sequentially when the ENTER key is pressed.  When all lines have been displayed, the previous screen is displayed.

3.   Lots reserved for the line can be displayed by pressing F16 from the line detail screen for lot-assignable item.

4.   The positions on the Configuration Template can be accessed through the use of F23-Cfg Template.

G.   Recap

1.   This screen provides recap information about the sales order line.  The information is retrieved from the Sales Order Header file (OP100M1) and the Sales Order Line Detail file (OP100M2).

2.   The Tax, Cash Discount, and Net Amounts are calculated for display on the recap screen.

a.   In a VAT/GST and PST environment, the Tax Amount is the sum of the Gross VAT/GST and PST Amounts.  Otherwise, the Tax Amount is the Amount Subject to Tax times the sum of the State, County, and City Tax Rates.  In a VAT environment, if the customer is subject to VAT surcharge, the tax amount also includes the surcharge amount.  (See VAT/GST and PST processing key concept section of Accounts Receivable User Manual for more information on VAT/GST and PST processing).

b.   The GST/PST Cash Discount Amount is the Amount Subject to Cash Discount times the Cash Discount Percent.

c.   The Net Amount is the sum of the Sales Amount, Other Charges, and Tax Amount, less the Cash Discount Amount.

3.   The Select field can be used to display either the Line Detail (OP100S04) screen, the Blanket Schedule screen (OP115S02), or the Release Detail screen (OP800S09). 

a.   If X has been entered in the Select field for a specific line or if a Line Number has been entered, and the ENTER key is pressed, the line detail screen is displayed. 

b.   If the order is a Blanket Order and uses the Blanket Shipment Schedule feature, entering an S in the Select field and pressing the ENTER key, will display the blanket schedule screen.  If the order does not use blanket shipment scheduling, an error message will be displayed.

H.   Blanket Schedule

1.   This screen provides shipment scheduling information about the sales order line.  This information is retrieved  from the Blanket Order Schedule file (OP100M5) only if the order is a Blanket Order and uses blanket shipment scheduling.

2.   If a valid Line Number has been entered, shipment schedule detail information for the order line is retrieved from the Blanket Order Schedule file (OP100L31).  If a record is found, it is displayed. 

3.   If the blanket shipment schedule details have been displayed and ENTER is pressed, the previous screen is displayed.

I.    Release Detail

1.   This screen provides detailed release information about the sales order line.  This includes the common information about the sales order line and a subfile showing the details of all the releases of the line.  This information is retrieved from the Sales Order Line file (OP100M2).

2.   When you press F14 - Include Zero Orders, the subfile information that is displayed includes closed releases and releases that have no shipment or inventory reservation.

J.   Comments

1.   This screen provides comments and/or customer messages for a specific sales order.  The comments are retrieved from Sales Order Comment file (OP100M3).

2.   If the Line Number is zero, order level comments and customer messages are displayed.

3.   If a valid Line Number has been entered, comments for that order line are displayed.  If another page of comments is available, the next page is displayed when the ENTER key is pressed.  If another page is not available, the comments for the next line are displayed sequentially when the ENTER key is pressed.  If a valid extended comment code is entered for either the header or the line, the extended comments are displayed.

4.   If all comments have been displayed and the previous screen was the header screen, the line detail screen is displayed.  If the previous screen was not the header screen, the previous screen is displayed.

K.   Direct Distribution Window

1.   The Direct Distribution Information Window program (DIRCTWIN) is called.

OP800E Program Menu