VerifyAndGetLocationMaster

Verify And Get Location Master

Major Business Rule

Object Name: XS4100

Parent DLL: COPBASE

Location: Client/Server

Language: C

Functional Description

Purpose

This business function verifies that the Location Master (F4100) record exists and returns a pointer 
to the Location Master Record.  You can retrieve a record from F4100 using one of six different 

indexes. 



Setup 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. MCU, LOCN
2. MCU, WSQP, LOCN

3. MCU, WSQQ, LOCN

4. MCU, WSQR, LOCN

5. MCU, CGRP

6. MCU, PZON

• 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).



Technical Specification




2.4Processing 

Initialize the DS F4100Pointer to NULL.
Fetch the Location Master 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 = '3138' (Invalid Location).
If DS Suppress Error Message is not equal to '1', SetGBRError where error message is '3138' ( 

Invalid Location ) 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 Location Master information.

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

Location Master Record.

Allocate memory for the Location Master Record.
If Memory Allocation is successful, Assign DS F4100 Pointer = Address of Location 

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


Returns:

If Call Type is equal to '1' and the fetch fails, return Error Message ID '3138' (Invalid 
Location).

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

DS4100 - Verify And Get Location Master

Parameter NameData ItemData TypeReq/OptI/O/Both
cReturnPointerFlagEV01charNONENONE

Special Input Expected
1=Return Pointer  

0=Do not return  pointerab 


^

cCallTypeEV01charNONENONE

Special Input Expected
1=Verify that record exists 

2=Verify that record does not  existab 



^

cSuppressErrorMessagesEV01charNONENONE

Special Input Expected
1=Suppress runtime error message handling  

0=Allow runtime error message handling


^

szIndexDTAIcharNONENONE

Special Input Expected
Pass in the number that identifies the index used to fetch the  recordab 


^

szKeysDTAIcharNONENONE

Special Input Expected
Pass the number of key fields used to fetch the  recordab 


^

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.

idF4100PointerGENLNGIDNONENONE

General purpose ID variable.

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.

szLocationLOCNcharNONENONE

The storage location from which goods will be moved.

mnPutAwaySequenceWSQPMATH_NUMERICNONENONE

A number that you assign to a location to determine its place in the putaway sequence. Putaway is the movement of inventory to storage 
after receipt. A sequence of locations describes the path that warehouse employees follow through the warehouse during movement tasks. 
You can specify in the Movement Instructions (P46095) whether the system uses the putaway sequence as a tiebreaker when there is more than 
one location selected for putaway. For example, you can establish sequencing for the most efficient putaway routing.

mnReplenishmentSequenceWSQRMATH_NUMERICNONENONE

A number that you assign to a location to determine its place in the replenishment sequence. Replenishment is the movement of inventory 
from storage locations to picking locations. A sequence of locations describes the path that warehouse employees follow through the 
warehouse during movement tasks. You can specify in the Movement Instructions (P46095) whether the system uses the replenishment sequence 
as a tiebreaker when there is more than one location selected to replenish from. For example, you can establish sequencing for the most 
efficient replenishment routing.

mnPickSequenceWSQQMATH_NUMERICNONENONE

A number that you assign to a location to determine its place in the picking sequence. Picking is the movement of inventory from storage to 
satisfy an order. A sequence of locations describes the path that warehouse employees follow through the warehouse during movement 
tasks. You can specify in the Movement Instructions (P46095) whether the system uses the picking sequence as a tiebreaker when there is 
more than one location selected to pick from. For example, you can establish sequencing for the most efficient pick routing.

szLocationCharGroupCGRPcharNONENONE

A code (system 46/type LC) that identifies a group of locations that share the same characteristics. A location characteristics group defines 
the characteristics for all locations that belong to the group. After you set up a location characteristics group, you can assign locations to the 
group through Location Characteristics (P46021).

szPutAwayZonePZONcharNONENONE

A code (system 46/type ZN) that identifies areas in the warehouse where goods are put away or stored.

Related Functions

B4000460 Free Ptr To Data Structure

Related Tables

F4100 Location Master