F4802InsertMessageDescription

F4802 Insert Message Desc

Minor Business Rule

Object Name: B4800070

Parent DLL: CMFG

Location: Client/Server

Language: C

Functional Description

Purpose

This function will insert a message description into the Work Order Instructions (F4802) table.  The 
message depends on the Message Type passed in.


Setup Notes and Prerequisites


Special Logic




Technical Specification



1)Select records based on key values passed in.

2)Sort the records in descending order by Line Number LINS.

3)Position cursor on first record.

4)If no record(s) were found.

'b7Copy passed in Order Number (DOCO), Order Type (DCTO), Suffix (SFXO) to respective 
database fields.  Move 'A' into Record Type (TYPR) database field.  Move '1' to Line Number (LINS) 

database field.

5)Else

'b7Add one (1) to Line Number (LINS) database field.
6)Get the Current Date.

7)If Message Type is equal to 'C'

'b7Replace Canceled Static Text's mm with Current Date's month.
'b7Replace Canceled Static Text's dd with Current Date's day.

'b7Replace Canceled Static Text's yy with Current Date's year.

'b7Move Canceled Static Text into Work Order Description (SRDS) database field.

8)If Message Type is equal to 'E'

'b7Replace the first Expedited Static Text's mm with Date Requested' month.
'b7Replace the first Expedited  Static Text's dd with Date Requested' day.

'b7Replace the first Expedited Static Text's yy with Date Requested' year.

'b7Replace the second Expedited Static Text's mm with Recommended Complete Date's  month.

'b7Replace the second Expedited  Static Text's dd with Recommended Complete Date's day.

'b7Replace the second Expedited Static Text's yy with Recommended Complete Date's year.

'b7Replace the third Expedited Static Text's mm with Current Date's month.

'b7Replace the third Expedited  Static Text's dd with Current Date's day.

'b7Replace the third Expedited Static Text's yy with Current Date's year.

'b7Move Expedited Static Text into Work Order Description (SRDS) database field.

9)If Message Type is equal to 'D'

'b7Replace the first Deferred Static Text's mm with Date Requested month.
'b7Replace the first Deferred Static Text's dd with Date Requested day.

'b7Replace the first Deferred Static Text's yy with Date Requested year.

'b7Replace the second Deferred Static Text's mm with Recommended Complete Date's  month.

'b7Replace the second Deferred Static Text's dd with Recommended Complete Date's day.

'b7Replace the second Deferred Static Text's yy with Recommended Complete Date's year.

'b7Replace the third Deferred Static Text's mm with Current Date's month.

'b7Replace the third Deferred Static Text's dd with Current Date's day.

'b7Replace the third Deferred Static Text's yy with Current Date's year.

'b7Move Deferred Static Text into Work Order Description (SRDS) database field. 

10)Insert the record.


Returns:

1.)  Error "3143" is returned is set on or returned if error occurs on I/O functions.






^

Data Structure

D4800070 - F4802 Insert Message Description

Parameter NameData ItemData TypeReq/OptI/O/Both
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.

szOrderTypeDCTOcharNONENONE

A user defined code (00/DT) that identifies the type of document. This code also indicates the origin of the transaction. J.D. Edwards has 
reserved document type codes for vouchers, invoices, receipts, and time sheets, which create automatic offset entries during the post 
program. (These entries are not self-balancing when you originally enter them.) The following document types are defined by J.D. Edwards and 
should not be changed: P Accounts Payable documents   R Accounts Receivable documents   T Payroll documents   I Inventory documents  
O Purchase Order Processing documents   J General Accounting/Joint Interest Billing documents   S Sales Order Processing documents

szSuffixSFXOcharNONENONE

In the A/R and A/P systems, a code that corresponds to the pay item. In the Sales Order and Procurement systems, this code identifies 
multiple transactions for an original order. For purchase orders, the code is always 000. For sales orders with multiple partial receipts against an 
order, the first receiver used to record receipt has a suffix of 000, the next has a suffix of 001, the next 002, and so on.

cRecordTypeTYPRcharNONENONE

The detail specification record type. Record types are user defined. You can set them up on the Detail Specification Types form and use 
them to describe certain types of work order or engineering change order information.

cSuppressErrorHandlingEV01charNONENONE

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

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.

cMessageTypeMSGTcharNONENONE

Message Type must equal 'C', 'E', or 'D', otherwise, no records will be  insertedab 

^

jdDateRequestedDRQJJDEDATENONENONE

Required for Message Type 'E' or 'D'.  Date Requested is inserted into  message.ab 

^

jdRecommendedCompleteDateRRQJJDEDATENONENONE

Required for Message Type 'E' or 'D'.  Recommended Complete date is inserted into message
^

szCancelledStaticTextSRDScharNONENONE

Required for Message Type 'C'.  Text is inserted into message.
English Value = 'Order Canceled on mm/dd/yy'

^

szExpeditedStaticTextSRDScharNONENONE

Required for Message Type 'E'.  Text is inserted into message.
English Value = 'Order Expedited from mm/dd/yy to mm/dd/yy on mm/dd/yy'

^

szDeferredStaticTextSRDScharNONENONE

Required for Message Type 'D'.  Text is inserted in message.
English Value = 'Order Deferred from mm/dd/yy to mm/dd/yy on mm/dd/yy'

^

Related Functions

None

Related Tables

F4802 Work Order Instructions File