ValidateAccountsForReceiptLines

Validate Accounts for Receipt Lines - Brazil - 43A

Minor Business Rule

Object Name: B7602000

Parent DLL: CLOC

Location: Client/Server

Language: C

Business Function Specification

Source NameB7602000DesignerMiriam Kato
Data Structure 
D7602000ProgrammerMiriam Kato
Function Name
 Validate AAI and AccountSystem Code76
Function CategoryInquiry
Function UseGET

Revisions Log 
DateProgrammerSAR NumberDescription
06/05/98Miriam Kato1844117Created



1.Functional Description

1.1Purpose
This Business Function validates the distribution AAI and account for ICMS Substitution, ICMS Substitution Recoverable, IPI, IPI Recoverable, ICMS 
Recoverable, Repasse and Trade Discount to the PO Receipts File (F43121).


1.2Setup Notes and Prerequisites


These setup notes refer to the global process.

1.UDC 76/GL: entries  SUB, SBR, IPI, IPR, ICR,REP, TDC
2.UDC 76/PU, Special Handling Code with 3 characters. See Special Logic.

3.Distribution AAIs for Table Numbers 4385 (Debit) and 4390 (Credit)

4.Accounts for each entry in the chart of accounts


1.3Special Logic


The recoverability flags for IPI, ICMS and ICMS Substitution are defined in the Special Handling Code for the UDC 76/PU. In order to read each one 
separately, the following offsets were defined:


#defineIPI_RECOV_POS0(IPI)

#defineICMS_RECOV_POS1(ICMS)

#defineICMS_SUBSRECOV_POS2(ICMS Substitution)


Technical Specifications

2.1 Parameters:

Data Item Data Structure DescriptionI/ORequiredNotes
BNNFmnNotaFiscalNumberIYNota Fiscal Number , from Report Interconnect

BSERszNotaFiscalSeriesIYNota Fiscal Series, from RI

N001mnNextNumberIYNota Fiscal Next Number 001, RI

DCTszDocumentTypeIYNota Fiscal Document Type, RI

EV01cReturnErrorOYif 0, no error; 1, error

NXTRszNextStatusIYFrom R76B804 processing options

LTTRszLastStatausIYFrom R76B804 processing options

AN8VmnAddNoVendorIYVendor Number, from Report Interconnect

LNIDmnLineNumberOOutput value, if error in validation

ANUMmnAaiTableNumberOOutput value, if error in validation

COszCompanyOOutput value, if error in validation

DCTszDocumentTypeOOutput value, if error in validation

GLCszGlClassOOutput value, if error in validation

MCUszCostCenterOOutput value, if error in validation

OBJszObjectAccountOOutput value, if error in validation

SUBszSubsidiaryOOutput value, if error in validation

VL01szGeneralTextOOutput value, if error in validation


2.2Related Tables 

Table Table Description
F7611BNota Fiscal  Detail


2.3Related Business Functions

Source NameFunction Name
B7601080Get Distribution AAI and Validate Account




2.4Processing 

General Logic - Flow

Main

Select all records for The Nota Fiscal Header and Vendor received in the parameters.
While record exists do

Get Recoverability Flags from UDC 76/PU, key = fdbcfc
Validate Line (  ICMS Substitution )

If ICMS Recoverable Flag = 1

Validate Line ( ICMS Substitution Recoverable )
Endif
Validate Line ( IPI )

If IPI Recoverable Flag = 1

Validate Line ( IPI Recoverable )
Endif
If ICMS Recoverable Flag = 1

Validate Line ( ICMS Recoverable )
Endif
Validate Line ( Repasse )

Validate Line ( Trade Discount )

Enddo

Validate Line (Amount, Line Code, dsF7611B )


If ( Amount != 0 )

Compose new GL Class = Line Code + fdglc
Read UDC 76/GL, key = new GL Class

If read ok,

// Get Distribution and Validate Account
call B7601080 (fdco, fdpdct, new GL Class, fdmcu)
Endif

Endif




^

Data Structure

D7602000 - Validate Accounts for Receipt Lines - Brazil          - 43A


Data Item Data Structure DescriptionI/ORequiredNotes
BNNFmnNotaFiscalNumberIYNota Fiscal Number , from Report Interconnect

BSERszNotaFiscalSeriesIYNota Fiscal Series, from RI

N001mnNextNumber  IYNota Fiscal Next Number 001, RI

DCTszDocumentTypeIYNota Fiscal Document Type, RI

EV01cReturnError       OYif 0, no error; 1, error

NXTRszNextStatus       IYFrom R76B804 processing options

LTTRszLastStataus       IYFrom R76B804 processing options

AN8VmnAddNoVendor       IYVendor Number, from Report Interconnect

LNIDmnLineNumber       OOutput value, if error in validation

ANUMmnAaiTableNumberOOutput value, if error in validation

COszCompany       OOutput value, if error in validation

DCTszDocumentType       OOutput value, if error in validation

GLCszGlClass       OOutput value, if error in validation

MCUszCostCenter       OOutput value, if error in validation

OBJszObjectAccount       OOutput value, if error in validation

SUBszSubsidiary       OOutput value, if error in validation

VL01szGeneralText       OOutput value, if error in validation


^

Parameter NameData ItemData TypeReq/OptI/O/Both
mnNotaFiscalNumberBNNFMATH_NUMERICOPTNONE

A six-character number that identifies a nota fiscal. The number consists of the nota fiscal number and the nota fiscal series.  

szNotaFiscalSeriesBSERcharOPTNONE

A two-character number that along with the nota fiscal number, identifies a nota fiscal. The Nota Fiscal Series field is the second key that the 
system uses to access a specific nota fiscal.

mnNextNumber001N001MATH_NUMERICOPTNONE

The number that the system will assign next. The system can use next numbers for voucher numbers, invoice numbers, journal entry 
numbers, employee numbers, address numbers, contract numbers, and sequential W-2s. You must use the next number types already 
established unless you provide custom programming.

szDocumentTypeDCTcharOPTNONE

A user defined code (00/DT) that identifies the origin and purpose of the transaction.  PeopleSoft reserves several prefixes for document 
types, such as, vouchers, invoices, receipts, and timesheets. The reserved document type prefixes for codes are: P Accounts payable 
documents R Accounts receivable documents  T Time and Pay documents I Inventory documents  O Purchase order documents  S Sales order 
documents 

szStatusCodeNextNXTRcharOPTNONE

A user defined code (system 40/type AT) indicating the next step in the order flow of the line type.

szStatusCodeLastLTTRcharOPTNONE

A code (system 40/type AT) specifying the last step in the processing cycle that this order line has successfully completed.

cReturnStatusEV01charOPTNONE

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

mnAddNoVendorAN8VMATH_NUMERICOPTNONE

The address book number of the supplier or subcontractor.

mnLineNumberLNIDMATH_NUMERICOPTNONE

A number that identifies multiple occurrences, such as line numbers on a purchase order or other document. Generally, the system assigns 
this number,but in some cases you can override it.

mnAaiTableNumberANUMMATH_NUMERICOPTNONE

A number used to specify sequence and retrieve accounting information.

szCompanyCOcharOPTNONE

A code that identifies a specific organization, fund, or other reporting entity. The company code must already exist in the Company 
Constants table (F0010) and must identify a reporting entity that has a complete balance sheet. At this level, you can have intercompany 
transactions. Note: You can use company 00000 for default values such as dates and automatic accounting instructions. You cannot use company 00000 
for transaction entries.

szDocumentType_2DCTcharOPTNONE

A user defined code (00/DT) that identifies the origin and purpose of the transaction.  PeopleSoft reserves several prefixes for document 
types, such as, vouchers, invoices, receipts, and timesheets. The reserved document type prefixes for codes are: P Accounts payable 
documents R Accounts receivable documents  T Time and Pay documents I Inventory documents  O Purchase order documents  S Sales order 
documents 

szGlClassGLCcharOPTNONE

A code that determines the trade account that the system uses as the offset when you post invoices or vouchers. The system concatenates 
the value that you enter to the AAI item RC (for Accounts Receivable) or PC (for Accounts Payable) to locate the trade account. For 
example, if you enter TRAD, the system searches for the AAI item RCTRAD (for receivables) or PCTRAD (for payables).  You can assign up to four 
alphanumeric characters to represent the G/L offset or you can assign the three-character currency code (if you enter transactions in a 
multicurrency environment). You must, however, set up the corresponding AAI item for the system to use; otherwise, the system ignores the G/L 
offset and uses the account that is set up for PC or RC for the company specified.  If you set up a default value in the G/L Offset field of the 
customer or supplier record, the system uses the value during transaction entry unless you override it.  Note: Do not use code 9999. It is reserved for 
the post program and indicates that offsets should not be created.

szCostCenterMCUcharOPTNONE

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.

szObjectAccountOBJcharOPTNONE

The portion of a general ledger account that refers to the division of the Cost Code (for example, labor, materials, and equipment) into 
subcategories. For example, you can divide the Cost Code for labor into regular time, premium time, and burden. Note: If you use a flexible chart of 
accounts and the object account is set to 6 digits, J.D. Edwards recommends that you use all 6 digits. For example, entering 000456 is not 
the same as entering 456 because if you enter 456 the system enters three blank spaces to fill a 6-digit object.

szSubsidiarySUBcharOPTNONE

A subset of an object account. Subsidiary accounts include detailed records of the accounting activity for an object account.

szGeneralTextVL01charOPTNONE

The list of selection values associated with a data selection item in the Dream Writer. This list is generated by the use of the *VALUES 
keyword in data selection setup. Elements 1 and 2 are also used to contain the upper and lower value for the keyword *RANGE used by the 
data selection in the Dream Writer.

szPOLineTypeFRTLNTYcharOPTNONE

A code that controls how the system processes lines on a transaction. It controls the systems with which the transaction interfaces, such as 
General Ledger, Job Cost, Accounts Payable, Accounts Receivable, and Inventory Management. It also specifies the conditions under 
which a line prints on reports, and it is included in calculations. Codes include the following: S Stock item   J Job cost   N Nonstock item   F Freight  
T Text information   M Miscellaneous charges and credits   W Work order

cLandedCostFlagEV01charOPTNONE

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

szPOLineTypeSEGLNTYcharOPTNONE

A code that controls how the system processes lines on a transaction. It controls the systems with which the transaction interfaces, such as 
General Ledger, Job Cost, Accounts Payable, Accounts Receivable, and Inventory Management. It also specifies the conditions under 
which a line prints on reports, and it is included in calculations. Codes include the following: S Stock item   J Job cost   N Nonstock item   F Freight  
T Text information   M Miscellaneous charges and credits   W Work order

szPOLineTypeEXPLNTYcharOPTNONE

A code that controls how the system processes lines on a transaction. It controls the systems with which the transaction interfaces, such as 
General Ledger, Job Cost, Accounts Payable, Accounts Receivable, and Inventory Management. It also specifies the conditions under 
which a line prints on reports, and it is included in calculations. Codes include the following: S Stock item   J Job cost   N Nonstock item   F Freight  
T Text information   M Miscellaneous charges and credits   W Work order

Related Functions

None

Related Tables

None