Chart of Accounts

The page explains how to query chart of account and account groups on Snowflake

Overview

Chart of Accounts (COA) is an index of all the financial accounts in the general ledger of a company. The chart of accounts is often hierarchical in nature and broken down into subcategories.

Leapfin allows organizations to configure their chart of accounts, so that account data stay consistent between Leapfin and the rest of financial systems, such as Netsuite.

Each ledger account with in COA contains following properties.

  • Account Number: numeric value presenting the ledger account.
  • Account Name: name of the ledger account.
  • Unique Account ID: a unique id generated by Leapfin baed on account number and name.
  • Account Group: category the ledger account. For example, "Asset", "Liability", "Income", etc.
  • Increasing Side: increasing side of the ledger account. Acceptable values are "dr" and "cr". For example, if increasing side is "dr", the all debts will be displayed as positive numbers and all credits will be negative.

🚧

Chart of Accounts Structure

Leapfin currently supports only two level of hierarchies for COA: ledger account and account group.

Modify COA

Account Number, Account Name, Account Group, and Increase Side can all be modified after COA is created. The only non-editable property is Unique Account ID, which the hook that associate journal entries with ledger accounts.

Once a ledger account is modified the changes are automatically applied to all historical and future JE. If the intention is to modify the account only for future JE, then a new ledge account should be create instead of modifying the existing one.

Deletion of ledger account is not allowed if any JE has been booked in that account. Otherwise, the JE data will be compromised. Instead, ledger accounts that are no longer needed can be simply abandoned by removing its usage in transaction scenario configurations.

Query COA

Chart of accounts information is stored in two tables. The VW_LK_ACCOUNT table contains details of each ledger accounts, and the VW_LK_ACCOUNT_GROUP table contains details of account groups.

Data schema for VW_LK_ACCOUNT table

Column NameDescription
ACCOUNT_IDthe serial number of ledger account.
ACCOUNTthe unique identifier of ledger account
ORGANIZATION_IDthe unique identifier of the account. This is an internal id created by Leapfin.
DISPLAY_NAMEthe display name of the ledger account
INCREASE_SIDEthe increasing side of the ledger account. Acceptable values are "dr" and "cr". For example, if increasing side is "dr", the all debts will be displayed as positive numbers and all credits will be negative.
ACCOUNT_NUMBERthe numeric value presenting the ledger account
ACCOUNT_GROUP_IDthe serial number of the account group. To get account group details, join with VW_LK_ACCOUNT_GROUP table.
ACCOUNT_RANKthe numeric order of the ledger account, indicating the sequence display on Leapfin's revenue page and report. Account with smaller value will be display on top within the account group.
CREATED_AT_DTthe date-time when the ledger account is created by Leapfin. Value format: "2022-07-14 23:01:26.400"
UPDATED_AT_DTthe date-time when the ledger account is last updated by Leapfin. Value format: "2022-07-14 23:01:26.400"

Data schema for VW_LK_ACCOUNT_GROUP table

Column NameDescription
ACCOUNT_GROUP_IDthe serial number of the account group. This is also the unique identifier created by Leapfin
ORGANIZATION_IDthe unique identifier of the account. This is an internal id created by Leapfin.
ACCOUNT_GROUP_DESCthe display name of the account group
RANKthe numeric order of the account group, indicating the sequence display on Leapfin's revenue page and report. Account group with smaller value will be display on top.
CREATED_AT_DTthe date-time when the account group is created by Leapfin. Value format: "2022-07-14 23:01:26.400"
UPDATED_AT_DTthe date-time when the account group is last updated by Leapfin. Value format: "2022-07-14 23:01:26.400"