ERP/3.0/Developers Guide/Database Model/org.openbravo.model.financialmgmt.gl/GL JournalLine
GL_JournalLine
- Name:GL_JournalLine
- Classname:FinancialMgmtGLJournalLine
This table contains the following columns:
Name | Nullable | Data Type | Description
|
User1_ID | Yes | VARCHAR (32) | The user defined element displays the optional elements that have been defined for this account combination. |
User2_ID | Yes | VARCHAR (32) | The user defined element displays the optional elements that have been defined for this account combination. |
C_ValidCombination_ID | Yes | VARCHAR (32) | The Combination identifies a valid combination of element which represent a GL account. |
IsActive | No | CHAR (1) | There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reporting. There are two reasons for de-activating and not deleting records:
(1) The system requires the record for auditing purposes. (2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are existing invoices for it. By de-activating the Business Partner you prevent it from being used in future transactions. |
C_Activity_ID | Yes | VARCHAR (32) | Activities indicate tasks that are performed and used to utilize Activity based Costing |
A_Asset_ID | Yes | VARCHAR (32) | Any item of economic value owned by the corporation, especially that which could be converted to cash. |
C_Bpartner_ID | Yes | VARCHAR (32) | A Business Partner is anyone with whom you transact. This can include a customer, vendor, employee or any combination of these. |
AD_Client_ID | No | VARCHAR (32) | A Client is a company or a legal entity. You cannot share data between Clients. |
C_Costcenter_ID | Yes | VARCHAR (32) | Division that adds to the cost of an organization. Internal structure for cost allocation. |
CreatedBy | No | VARCHAR (32) | The Created By field indicates the user who created this record. |
Created | No | TIMESTAMP (7) | The Created field indicates the date that this record was created. |
AmtAcctCr | No | DECIMAL | The Account Credit Amount indicates the transaction amount converted to this organization's accounting currency |
C_Currency_ID | No | VARCHAR (32) | Indicates the currency to be used when processing this document. |
CurrencyRateType | No | VARCHAR (60) | The Conversion Rate Type indicates the type of rate to use when retrieving the conversion rate. It allows you to define multiple rates for the same to and from currency. For example you may have a set of rates used for daily transactions with a rate type of SPOT and rates for currency revaluation defined as REVAL. |
AmtAcctDr | No | DECIMAL | The Account Debit Amount indicates the transaction amount converted to this organization's accounting currency |
Description | Yes | NVARCHAR (255) | A description is limited to 255 characters. |
EM_Aprm_Addpayment | Yes | CHAR (1) | Launches a process to add a payment to the selected invoice. |
FIN_Financial_Account_ID | Yes | VARCHAR (32) | Financial account used to deposit / withdrawal money such as bank accounts or petty cash |
AmtSourceCr | No | DECIMAL | The Source Credit Amount indicates the credit amount for this line in the source currency. |
AmtSourceDr | No | DECIMAL | The Source Debit Amount indicates the credit amount for this line in the source currency. |
C_Glitem_ID | Yes | VARCHAR (32) | General ledger item. |
Account_ID | Yes | VARCHAR (32) | |
IsGenerated | No | CHAR (1) | The Generated checkbox identifies a journal line that was generated from a source document. Lines could also be entered manually or imported. |
GL_Journal_ID | No | VARCHAR (32) | The General Ledger Journal identifies a group of journal lines which represent a logical business transaction |
GL_JournalLine_ID | No | VARCHAR (32) | The General Ledger Journal Line identifies a single transaction in a journal. |
Line | No | DECIMAL (10,0) | Indicates the unique line for a document. It will also control the display order of the lines within a document. |
Open_Items | No | CHAR (1) | |
AD_Org_ID | No | VARCHAR (32) | An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations. |
C_Debt_Payment_ID | Yes | VARCHAR (32) | Refers to the amount of money to be paid or collected. |
Paymentdate | Yes | TIMESTAMP (7) | |
FIN_Paymentmethod_ID | Yes | VARCHAR (32) | |
M_Product_ID | Yes | VARCHAR (32) | Identifies an item which is either purchased or sold in this organization. |
C_Project_ID | Yes | VARCHAR (32) | Identifier of a project defined within the Project & Service Management module. |
Qty | Yes | DECIMAL | The Quantity indicates the number of a specific product or item for this document. |
CurrencyRate | No | DECIMAL | The Currency Conversion Rate indicates the rate to use when converting the source currency to the accounting currency |
FIN_Payment_ID | Yes | VARCHAR (32) | Payment event |
C_Campaign_ID | Yes | VARCHAR (32) | The Campaign defines a unique marketing program. Projects can be associated with a pre defined Marketing Campaign. You can then report based on a specific Campaign. |
C_Salesregion_ID | Yes | VARCHAR (32) | The Sales Region indicates a specific area of sales coverage. |
C_Tax_ID | Yes | VARCHAR (32) | The Tax indicates the type of tax for this document line. |
C_UOM_ID | Yes | VARCHAR (32) | The UOM defines a unique non monetary unit of measure |
Updated | No | TIMESTAMP (7) | The Updated field indicates the date that this record was updated. |
UpdatedBy | No | VARCHAR (32) | The Updated By field indicates the user who updated this record. |
C_Withholding_ID | Yes | VARCHAR (32) | The Withholding indicates the type of withholding to be calculated. |
Columns
1st Dimension
- Physical column name: User1_ID
- Property Name: stDimension
- Reference: OBUISEL_Selector Reference
Foreign key column to User1 table, (column: User1_ID)
2nd Dimension
- Physical column name: User2_ID
- Property Name: ndDimension
- Reference: OBUISEL_Selector Reference
Foreign key column to User2 table, (column: User2_ID)
Accounting Combination
- Physical column name: C_ValidCombination_ID
- Property Name: accountingCombination
- Reference: OBUISEL_Selector Reference
Foreign key column to C_ValidCombination table, (column: C_ValidCombination_ID)
Active
- Physical column name: IsActive
- Property Name: active
- Reference: YesNo
- Default value: Y
Activity
- Physical column name: C_Activity_ID
- Property Name: activity
- Reference: OBUISEL_Selector Reference
Foreign key column to C_Activity table, (column: C_Activity_ID)
Asset
- Physical column name: A_Asset_ID
- Property Name: asset
- Reference: OBUISEL_Selector Reference
Foreign key column to A_Asset table, (column: A_Asset_ID)
Business Partner
- Physical column name: C_Bpartner_ID
- Property Name: businessPartner
- Reference: Search
Foreign key column to C_BPartner table, (column: C_BPartner_ID)
Client
- Physical column name: AD_Client_ID
- Property Name: client
- Reference: TableDir
Foreign key column to AD_Client table, (column: AD_Client_ID)
Cost Center
- Physical column name: C_Costcenter_ID
- Property Name: costCenter
- Reference: OBUISEL_Selector Reference
Foreign key column to C_Costcenter table, (column: C_Costcenter_ID)
Created By
- Physical column name: CreatedBy
- Property Name: createdBy
- Reference: Search
Foreign key column to AD_User table, (column: AD_User_ID)
Creation Date
- Physical column name: Created
- Property Name: creationDate
- Reference: DateTime
- Default value: SYSDATE
Credit
- Physical column name: AmtAcctCr
- Property Name: credit
- Reference: Amount
- Default value: 0
Currency
- Physical column name: C_Currency_ID
- Property Name: currency
- Reference: TableDir
Foreign key column to C_Currency table, (column: C_Currency_ID)
Callout: SL_JournalLineAmt
This column has a callout associated.
It is implemented by [1] Java Class.
Currency Rate Type
- Physical column name: CurrencyRateType
- Property Name: currencyRateType
- Reference: List
Callout: SL_JournalLineAmt
This column has a callout associated.
It is implemented by [2] Java Class.
List values: C_Conversion_Rate Types
The allowed values for this list are:
- A (Average): Average Rates
- C (Company): Company Rate
- U (User Type): User Rate Type
- M (Manual Rate): Manual Rate
- S (Spot): Spot Conversation Rate Type
- P (Period End): Period Conversion Type
- N (None): No Conversion Rate
- F (Fixed): Euro Fixed Currency
Debit
- Physical column name: AmtAcctDr
- Property Name: debit
- Reference: Amount
- Default value: 0
Description
- Physical column name: Description
- Property Name: description
- Reference: String
EM_APRM_Add Payment
- Physical column name: EM_Aprm_Addpayment
- Property Name: aPRMAddPayment
- Reference: Button
- Default value: Y
Financial Account
- Physical column name: FIN_Financial_Account_ID
- Property Name: financialAccount
- Reference: TableDir
Foreign key column to FIN_Financial_Account table, (column: Fin_Financial_Account_ID)
It has a validation "Financial Account Currency", with the following code
FIN_Financial_Account.C_Currency_ID = @C_CURRENCY_ID@
Foreign Currency Credit
- Physical column name: AmtSourceCr
- Property Name: foreignCurrencyCredit
- Reference: Amount
- Default value: 0
Callout: SL_JournalLineAmt
This column has a callout associated.
It is implemented by [3] Java Class.
Foreign Currency Debit
- Physical column name: AmtSourceDr
- Property Name: foreignCurrencyDebit
- Reference: Amount
- Default value: 0
Callout: SL_JournalLineAmt
This column has a callout associated.
It is implemented by [4] Java Class.
G/L Item
- Physical column name: C_Glitem_ID
- Property Name: gLItem
- Reference: TableDir
Foreign key column to C_Glitem table, (column: C_Glitem_ID)
GL Items
- Physical column name: Account_ID
- Property Name: gLItems
- Reference: Table
Foreign key column to C_Glitem table, (column: C_Glitem_ID)
It has a validation "GL Journal GL Items", with the following code
@Multi_Gl@='Y'
Callout: SL_Journal_MultiAcctSchema
This column has a callout associated.
It is implemented by [5] Java Class.
Generated
- Physical column name: IsGenerated
- Property Name: generated
- Reference: YesNo
- Default value: N
Journal Entry
- Physical column name: GL_Journal_ID
- Property Name: journalEntry
- Reference: Search
- This column is a child for a business object (is Parent)
Foreign key column to GL_Journal table, (column: GL_Journal_ID)
Journal Line
- Physical column name: GL_JournalLine_ID
- Property Name: id
- Reference: ID
Line No.
- Physical column name: Line
- Property Name: lineNo
- Reference: Integer
- This column is part of the table's identifier
Open Items
- Physical column name: Open_Items
- Property Name: openItems
- Reference: YesNo
- Default value: N
Organization
- Physical column name: AD_Org_ID
- Property Name: organization
- Reference: TableDir
Foreign key column to AD_Org table, (column: AD_Org_ID)
It has a validation "AD_Org show GL_Header child organizations", with the following code
(AD_ISORGINCLUDED(ad_org.ad_org_id, @Batch_Org@, ad_org.ad_client_id)<>-1 AND IsReady='Y') or
AD_ISORGINCLUDED(ad_org.ad_org_id, @Journal_Org@, ad_org.ad_client_id)<>-1 AND IsReady='Y'
Payment
- Physical column name: C_Debt_Payment_ID
- Property Name: payment
- Reference: Search
Foreign key column to C_Debt_Payment table, (column: C_Debt_Payment_ID)
Payment Date
- Physical column name: Paymentdate
- Property Name: paymentDate
- Reference: Date
Payment Method
- Physical column name: FIN_Paymentmethod_ID
- Property Name: paymentMethod
- Reference: TableDir
Foreign key column to FIN_PaymentMethod table, (column: Fin_Paymentmethod_ID)
It has a validation "FIN_PaymentMethodInFinancialAccountOrBPartnerAcc", with the following code
EXISTS(
SELECT FIN_PAYMENTMETHOD_ID FROM FIN_FINACC_PAYMENTMETHOD WHERE FIN_FINANCIAL_ACCOUNT_ID = CASE WHEN (@FIN_FINANCIAL_ACCOUNT_ID@ IS NOT NULL AND @FIN_FINANCIAL_ACCOUNT_ID@ <> COALESCE(,'-1')) THEN @FIN_FINANCIAL_ACCOUNT_ID@ ELSE (SELECT CASE WHEN ((TO_NUMBER(@AMTACCTDR@) - TO_NUMBER(@AMTACCTCR@)) > 0) THEN FIN_FINANCIAL_ACCOUNT_ID ELSE PO_FINANCIAL_ACCOUNT_ID END FROM C_BPARTNER WHERE C_BPARTNER_ID = @C_BPARTNER_ID@) END AND FIN_FINACC_PAYMENTMETHOD.FIN_PAYMENTMETHOD_ID = FIN_PAYMENTMETHOD.FIN_PAYMENTMETHOD_ID )
Product
- Physical column name: M_Product_ID
- Property Name: product
- Reference: OBUISEL_Selector Reference
Foreign key column to M_Product table, (column: M_Product_ID)
Project
- Physical column name: C_Project_ID
- Property Name: project
- Reference: Search
Foreign key column to C_Project table, (column: C_Project_ID)
Quantity
- Physical column name: Qty
- Property Name: quantity
- Reference: Quantity
- Default value: 0
Rate
- Physical column name: CurrencyRate
- Property Name: rate
- Reference: Number
- Default value: 0
Callout: SL_JournalLineAmt
This column has a callout associated.
It is implemented by [6] Java Class.
Related Payment
- Physical column name: FIN_Payment_ID
- Property Name: relatedPayment
- Reference: OBUISEL_Selector Reference
Foreign key column to FIN_Payment table, (column: Fin_Payment_ID)
Sales Campaign
- Physical column name: C_Campaign_ID
- Property Name: salesCampaign
- Reference: OBUISEL_Selector Reference
Foreign key column to C_Campaign table, (column: C_Campaign_ID)
Sales Region
- Physical column name: C_Salesregion_ID
- Property Name: salesRegion
- Reference: TableDir
Foreign key column to C_SalesRegion table, (column: C_SalesRegion_ID)
Tax
- Physical column name: C_Tax_ID
- Property Name: tax
- Reference: TableDir
Foreign key column to C_Tax table, (column: C_Tax_ID)
UOM
- Physical column name: C_UOM_ID
- Property Name: uOM
- Reference: TableDir
Foreign key column to C_UOM table, (column: C_UOM_ID)
Updated
- Physical column name: Updated
- Property Name: updated
- Reference: DateTime
- Default value: SYSDATE
Updated By
- Physical column name: UpdatedBy
- Property Name: updatedBy
- Reference: Search
Foreign key column to AD_User table, (column: AD_User_ID)
Withholding
- Physical column name: C_Withholding_ID
- Property Name: withholding
- Reference: TableDir
Foreign key column to C_Withholding table, (column: C_Withholding_ID)
Other Info
Indices
These are the indices for this table (for each index there is a list of all the columns included within it):
- GL_JOURNALLINE_JOURNAL_IDX Not Unique. Columns:
- GL_JOURNAL_ID
Check Constraints
These are the check constraints for this table:
- GL_JOURNALLINE_C_TAX_ID_CHK: C_TAX_ID IS NULL OR C_WITHHOLDING_ID IS NULL
- GL_JOURNALLINE_ISACTIVE_CHECK: ISACTIVE IN ('Y', 'N')
- GL_JOURNALLINE_ISGENERATED_CHK: ISGENERATED IN ('Y', 'N')
- GL_JOURNALLINE_MGL_GLJ_CHECK: C_VALIDCOMBINATION_ID IS NOT NULL AND ACCOUNT_ID IS NULL OR C_VALIDCOMBINATION_ID IS NULL AND ACCOUNT_ID IS NOT NULL
- GL_JOURNALLINE_OPENITEM_CHECK: OPEN_ITEMS = 'N' OR OPEN_ITEMS = 'Y' AND FIN_FINANCIAL_ACCOUNT_ID IS NOT NULL AND FIN_PAYMENTMETHOD_ID IS NOT NULL AND C_GLITEM_ID IS NOT NULL AND PAYMENTDATE IS NOT NULL