DTW_BST_FACT_BALANCE


Description

Balance fact table definition.

Columns

Column Type Size Nulls Auto Default Children Parents Comments
ACCOUNT_ID CHAR 36 null
DTW_BST_DIM_ACCOUNT.ACCOUNT_ID DTW_BST_FK_FACT_BALANCE_AC R

Account unique ID.

ENTRY_DATE_ID INT 10 null
DTW_BST_DIM_DATE.DATE_ID DTW_BST_FK_FACT_BALANCE_DATE R

Entry full date unique ID (year+month+day).

BALANCE_TYPE_ID CHAR 36 null
DTW_BST_DIM_BALANCE_TYPE.BALANCE_TYPE_ID DTW_BST_FK_FACT_BALANCE_TYPE R

Checking account balance type Unique ID.

CURRENCY CHAR 3 null

Balance operation currency (BRL, USS, etc).

ENTRY_ID CHAR 36 null

Entry unique ID.

AMOUNT DECIMAL 19 null

Balance operation amount.

SOURCE VARCHAR 100 null

Source application name that creates the fact balance

CREATED_AT DATETIME 26 CURRENT_TIMESTAMP(6)

Timestamp value to register a record creation time.

UPDATED_AT DATETIME 26 CURRENT_TIMESTAMP(6)

Timestamp value to register a record update time.

Indexes

Constraint Name Type Sort Column(s)
PRIMARY Primary key Asc/Asc/Asc/Asc ACCOUNT_ID + ENTRY_DATE_ID + BALANCE_TYPE_ID + ENTRY_ID
DTW_BST_FACT_BALANCE_CUR_IDX Performance Asc CURRENCY
DTW_BST_FACTBAL_ENTRYID_IDX Performance Asc ENTRY_ID
DTW_BST_FK_FACT_BALANCE_DATE Performance Asc ENTRY_DATE_ID
DTW_BST_FK_FACT_BALANCE_TYPE Performance Asc BALANCE_TYPE_ID

Relationships