VerifyAndGetPartsList

Verify And Get Parts List

Minor Business Rule

Object Name: B3100470

Parent DLL: CMFGBASE

Location: Client/Server

Language: C

1.Functional Description
The Functional Description section is to be cut from the Word document and pasted into the Notes 
section of the Business Function.


1.1Purpose
This business function verifies that the Parts List (F3111) record exists and returns a pointer to 
the Parts List Record.  You can retrieve a record from F3111 using one of eight different indexes. 


1.2Setup Notes and Prerequisites

• If a pointer to the record is returned, this pointer must be cleared in the application using the 
BSFN FreePtrtoDataStructure.

• The user passes to the business function the number of the index they want to use and the number of 
key fields within that index that will be used.

List of Indexes:
1. DOCO, OPSQ, BSEQ
2. CPIT, CMCU, DRQJ

3. MCU, CPIT, COBY, DOCO

4. DOCO, OPSQ, DRQJ, CMCU, LOCN, LOTN, CPIT

5. DOCO, CPIT, CMCU

6. COBY, DOCO, OPSQ

7. COBY, CPIT, CMCU, DRQJ

8. UKID

• The returned error message will display automatically on the message line and the appropriate field 
(if any) will be highlighted. This can be suppressed by turning on the "Suppress Error Message" flag. 

• Turn on the "Return Pointer" flag to have the business function return a pointer to the record. 
• Set the "Call Type" flag to a "1" to have the business function verify that the record exists. Set 
it to "2" to have the business function verify that the record does not exist (ie. it returns an error 

if a record is found).


1.3Special Logic

None.

2.Technical Specifications


2.4Processing

 

Initialize the DS F3111Pointer to NULL.
Fetch the Shop Floor Control Parts List Record corresponding to the index and keys entered by the 

user.  


If DS Call Type is equal to '1', return error messages.

Assign DS Error Message ID = '0002' (Record Invalid).
If DS Suppress Error Message is not equal to '1', SetGBRError where error message is '0002' ( Record 

Invalid ) and the first field in the index is highlighted.


If Fetch is successful, return pointer and messages.

If DS Call Type is equal to '2', return error messages.
Assign DS Error Message ID = '2463'.
If DS Suppress Error Message is not equal to '1', SetGBRError where error message is '2463' and 

the first field in the index is highlighted.

If DS Call Type is not equal to '2', return the Parts List information.

If  DS Call Type is not equal to '2' and DS Return Pointer is equal to '1', return pointer to the 

Parts List Record.

Allocate memory for the Parts List Record.
If Memory Allocation is successful, Assign DS F3111 Pointer = Address of Parts List Record.

If Memory Allocation is not successful, return error messages.

Assign DS Error Message ID = '4365' (No Memory).
If DS Suppress Error Message is not equal to '1', SetGBRError where error message is 

'4365' and first field in index is highlighted.


List of Indexes:

1.DOCO, OPSQ, BSEQ
2.CPIT, CMCU, DRQJ

3.MCU, CPIT, COBY, DOCO

4.DOCO, OPSQ, DRQJ, CMCU, LOCN, LOTN, CPIT

5.DOCO, CPIT, CMCU

6.COBY, DOCO, OPSQ

7.COBY, CPIT, CMCU, DRQJ

8.UKID


Returns:

If Call Type is equal to '1' and the fetch fails, return Error Message ID '0002' (Record Invalid).
If Call Type is equal to '2' and the fetch is successful, return Error Message ID '2463'.

If Return Pointer is equal to '1', the fetch is successful, and the memory allocation is successful, 

return the pointer to the data structure.


Data Structure

D3100470 - Verify And Get Parts List

Parameter NameData ItemData TypeReq/OptI/O/Both
cReturnPointerFlagEV01charNONENONE

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

cCallTypeEV01charNONENONE

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

cSuppressErrorMessagesEV01charNONENONE

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

szIndexDTAIcharNONENONE

A code that identifies and defines a unit of information. It is an alphanumeric code up to 8 characters long that does not allow blanks or 
special characters such as %, &, or +. You create new data items using system codes 55-59. You cannot change the alias.

szKeysDTAIcharNONENONE

A code that identifies and defines a unit of information. It is an alphanumeric code up to 8 characters long that does not allow blanks or 
special characters such as %, &, or +. You create new data items using system codes 55-59. You cannot change the alias.

szErrorMessageIDDTAIcharNONENONE

A code that identifies and defines a unit of information. It is an alphanumeric code up to 8 characters long that does not allow blanks or 
special characters such as %, &, or +. You create new data items using system codes 55-59. You cannot change the alias.

idF3111PointerGENLNGIDNONENONE

General purpose ID variable.

mnOrderNumberDOCOMATH_NUMERICNONENONE

A number that identifies an original document. This document can be a voucher, a sales order, an invoice, unapplied cash, a journal entry, 
and so on.

mnOperationSequenceOPSQMATH_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.

mnBubbleSequenceBSEQMATH_NUMERICNONENONE

A secondary bill of material sequence number that indicates the drawing bubble number.

mnComponentShortItemNumCPITMATH_NUMERICNONENONE

The short identifier for the component item number.

szComponentBranchCMCUcharNONENONE

A secondary or lower-level business unit. The system uses the value that you enter to indicate that a branch or plant contains several 
subordinate departments or jobs. For example, assume that the component branch is named MMCU. The structure of MMCU might be as follows:    
Branch/Plant - (MMCU)       Dept A - (MCU)       Dept B - (MCU)       Job 123 - (MCU)

jdDateRequestedDRQJJDEDATENONENONE

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

szBusinessUnitMCUcharNONENONE

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.

cCoByProductsCOBYcharNONENONE

A code that distinguishes standard components or ingredients from co-products,by-products, and intermediates. Co-products are 
(concurrent) end items as the result of a process. By-products are items that can be produced at any step of a process, but were not planned. 
Intermediate products are items defined as a result of a step but are automatically consumed in the following step. Generally, intermediates are 
nonstock items and are only defined steps with a pay-point for reporting purposes. Standard components (Discrete Manufacturing) or ingredients 
(Process Manufacturing) are consumed during the production process. Valid values are:    C Co-products    B By-products    I Intermediate 
products    Blank Standard components or ingredients

szLocationLOCNcharNONENONE

The storage location from which goods will be moved.

szLotNumberLOTNcharNONENONE

A number that identifies a lot or a serial number. A lot is a group of items with similar characteristics.

mnUniqueKeyIDUKIDMATH_NUMERICNONENONE

This field is a unique number used to identify a record in a file.

Related Functions

B4000460 Free Ptr To Data Structure

Related Tables

F3111 Work Order Parts List