ValidateAAICompletelyForCurrency

Validate Account Currency

Minor Business Rule

Object Name: B03B0233

Parent DLL: CFIN

Location: Client/Server

Language: C

1.Functional Description

1.1Purpose

The purpose of this business function is to validate the currency of accounts company 

and/or account currency based on the parameters which passed to it. This function also returns 

the account currency and accounts companys currency. The function requires account ID, base 

currency, and transaction currency. 


1.2Setup Notes and Prerequisites

N/A

1.3Special Logic

N/A

2.Technical Specifications


2.1Parameters:

Data Item Data Structure DescriptionI/ORequiredNotes

AIDszAccountIdIYThe account to be validated

BCRCszBaseCurrencyCodeIYThe base currency code of 

transaction

CRCDszTransactionCurrencyCodeIYThe transaction currency of 

transaction

ITEMszItemNumberINThe AAI Item number that is 

related to the above Account ID. This 

is an optional field. The function uses 

this field and the company number to 

provide detail information about the 

account in an error message.

COszCompanyINThe company that the above account 

ID belongs to. This is an optional 

field. The function uses this field and 

the item number to provide detail 

information about the account in an error 

message.

CRCDszAccountCurrencyOThe currency code of account. 

It contains valid value only when the 

account is a monetary account.

CRCDszAccountCompanyCurrencyOThe currency code of account's 

company



2.2Related Tables 

N/A 


2.3Related Business Functions

Source NameFunction Name B0000037Retrieve Account Currency

2.4Processing 

If currency processing is on,

If any required input parameter is blank, set error and terminate the process with 
error.

Retrieve account currency and accounts companys currency by calling function - 

B0000037.

If the function call is successful,

Compare the accounts company currency code to the passed in base currency code. 
If they are different, then set a specific error by using the passed in item 

number and company in the error text substitution. Terminate the process with 

error.

If account currency is not blank, compare the account currency code to the 

passed in Transaction currency code. If they are different, then set a specific 

error by using the passed in item number and company in the error text substitution. 

Terminate the process with error.

Else
Set error and terminate the process with error.

End if
End if

Terminate the process normally.


Data Structure

D03B0233 - Validate Account Currency

Parameter NameData ItemData TypeReq/OptI/O/Both
szAccountIdAIDcharREQINPUT

A number that the system assigns to each general ledger account in the Account Master table (F0901) to uniquely identify it. 

szBaseCurrencyCodeBCRCcharREQINPUT

A code that represents the currency of the company for a transaction. For a foreign currency transaction, this is the currency code of the 
domestic side of the transaction.

szTransactionCurrencyCodeCRCDcharOPTINPUT

A code that identifies the currency of a transaction. 

szItemNumberITEMcharOPTINPUT

A hard-coded field that defines an account or range of accounts used for a particular function. For example, item GLG4 defines the retained 
earnings account, which is used for annual close purposes. During processing, programs use the item number and company number to find 
the correct account to debit or credit. Along with company, the item (or range) is the key to the AAI table.

szCompanyCOcharOPTINPUT

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.

szAccountCurrencyCRCDcharOPTOUTPUT

A code that identifies the currency of a transaction. 

szAccountCompanyCurrencyCRCDcharOPTOUTPUT

A code that identifies the currency of a transaction. 

Related Functions

None

Related Tables

None