C_BankCashBalanceHistory

DDL: C_BANKCASHBALANCEHISTORY SQL: CBACCBALHIS Type: view CONSUMPTION Package: FCLM_BALANCE

Value Date Balance Details

C_BankCashBalanceHistory is a Consumption CDS View that provides data about "Value Date Balance Details" in SAP S/4HANA. It reads from 1 data source (P_BANKCASHBALANCEHISTORY) and exposes 22 fields with key fields BankAccountInternalID, CashBalanceDate, CashBalanceKey. It has 1 association to related views. It is exposed through 2 OData services (ASQL_F5175, BANKCASHBALANCE). Part of development package FCLM_BALANCE.

Data Sources (1)

SourceAliasJoin Type
P_BANKCASHBALANCEHISTORY P_BANKCASHBALANCEHISTORY from

Associations (1)

CardinalityTargetAliasCondition
[0..*] C_BkCshBalValDteBalPredatedFlw _PredatedFlow $projection.BankAccountInternalID = _PredatedFlow.BankAccountInternalID and $projection.CashBalanceDate < _PredatedFlow.ValueDate and $projection.CashBalanceDate >= _PredatedFlow.BankStatementDocPostingDate

Annotations (15)

NameValueLevelField
AbapCatalog.sqlViewName CBACCBALHIS view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
ClientHandling.algorithm #SESSION_VARIABLE view
AccessControl.authorizationCheck #CHECK view
EndUserText.label Value Date Balance Details view
Metadata.ignorePropagatedAnnotations true view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
VDM.viewType #CONSUMPTION view
UI.headerInfo.title.type #STANDARD view
UI.headerInfo.title.value BankAccountNumber view
UI.headerInfo.description.type #STANDARD view
UI.headerInfo.description.value BankAccountDescription view

OData Services (2)

ServiceBindingVersionContractRelease
ASQL_F5175 ASQL_F5175 C2 NOT_RELEASED
BANKCASHBALANCE BANKCASHBALANCE_O2 V2 C1 NOT_TO_BE_RELEASED_STABLE

Fields (22)

KeyFieldSource TableSource FieldDescription
KEY BankAccountInternalID BankAccountInternalID Technical ID
KEY CashBalanceDate CashBalanceDate
KEY CashBalanceKey CashBalanceKey
CompanyCode CompanyCode Receiver Company Code
CompanyCodeName CompanyCodeName Company Name
CashBalanceAmount CashBalanceAmount
CashBalanceCurrency CashBalanceCurrency
CashClosingValDteBalanceAmount CashClosingValDteBalanceAmount
CashClosingLedgerBalanceAmount CashClosingLedgerBalanceAmount
CashBalanceChannel CashBalanceChannel
CashBalanceChannelText
CashBalanceType CashBalanceType
CashBalanceTypeText
CreatedByUser CreatedByUser User Name
CreatedByUserName _User UserDescription Full Name
CashBalanceCreatedAtDateTime CashBalanceCreatedAtDateTime
BankStatementShortID BankStatementShortID Statement Short Key
OriginDocument OriginDocument
BankStatement BankStatement Bank Statement No.
BankAccountNumber BankAccountNumber Bank Account
BankAccountDescription BankAccountDescription
_PredatedFlow _PredatedFlow

Derived SQL interpretation, reconstructed from the parsed view metadata (data sources, associations, and field mappings). SAP annotations are omitted and the structure is reformulated as SQL — this is a functional approximation, not the verbatim SAP source.

-- Derived SQL interpretation of CDS view C_BankCashBalanceHistory.
-- Reconstructed from parsed metadata (data sources, associations, fields).
-- SAP annotations are omitted and the structure is reformulated as SQL;
-- this is a functional approximation, not the verbatim SAP source. Some join
-- conditions may be unavailable and a few CDS constructs are kept as-is.
-- SQL view name: CBACCBALHIS

CREATE VIEW C_BankCashBalanceHistory AS
SELECT
  BankAccountInternalID,
  CashBalanceDate,
  CashBalanceKey,
  CompanyCode,
  CompanyCodeName,
  CashBalanceAmount,
  CashBalanceCurrency,
  CashClosingValDteBalanceAmount,
  CashClosingLedgerBalanceAmount,
  CashBalanceChannel,
  _BalanceChannelText[1:Language = $session.system_language].CashBalanceChannelText AS CashBalanceChannelText,
  CashBalanceType,
  _BalanceTypeText[1:Language = $session.system_language].CashBalanceTypeText AS CashBalanceTypeText,
  CreatedByUser,
  _User.UserDescription AS CreatedByUserName,
  CashBalanceCreatedAtDateTime,
  BankStatementShortID,
  OriginDocument,
  BankStatement,
  BankAccountNumber,
  BankAccountDescription
FROM P_BANKCASHBALANCEHISTORY
LEFT OUTER JOIN C_BkCshBalValDteBalPredatedFlw AS _PredatedFlow ON BankAccountInternalID = _PredatedFlow.BankAccountInternalID AND CashBalanceDate < _PredatedFlow.ValueDate AND CashBalanceDate >= _PredatedFlow.BankStatementDocPostingDate  -- association [0..*]
;