P_CAScrtyDepReqCalculateAmount

DDL: P_CASCRTYDEPREQCALCULATEAMOUNT SQL: PCALREQAMT Type: view COMPOSITE Package: ODATA_O2C_FICA_SCRTY_DEP_MNG

Calculate Deposit Request Amounts

P_CAScrtyDepReqCalculateAmount is a Composite CDS View that provides data about "Calculate Deposit Request Amounts" in SAP S/4HANA. It reads from 1 data source (P_CAScrtyDepReqCalDocAmt) and exposes 15 fields with key fields CASecurityDeposit, CADocumentNumber. It has 3 associations to related views. Part of development package ODATA_O2C_FICA_SCRTY_DEP_MNG.

Data Sources (1)

SourceAliasJoin Type
P_CAScrtyDepReqCalDocAmt DocumentAmt from

Associations (3)

CardinalityTargetAliasCondition
[1..1] I_Currency _TransactionCurrency $projection.TransactionCurrency = _TransactionCurrency.Currency
[1..1] I_Currency _RefundCurrency $projection.RefundCurrency = _RefundCurrency.Currency
[1..1] I_Currency _PaymentCurrency $projection.PaymentCurrency = _PaymentCurrency.Currency

Annotations (7)

NameValueLevelField
AbapCatalog.sqlViewName PCALREQAMT view
ClientHandling.algorithm #SESSION_VARIABLE view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #NOT_REQUIRED view
VDM.viewType #COMPOSITE view
VDM.private true view

Fields (15)

KeyFieldSource TableSource FieldDescription
KEY CASecurityDeposit P_CAScrtyDepReqCalDocAmt CASecurityDeposit
KEY CADocumentNumber P_CAScrtyDepReqCalDocAmt CADocumentNumber Document Number
CAAmountInTransactionCurrency
CAPaidAmountInTransCurrency
CAPaymentAmountInPaytCurrency
CAReleasedAmtInPaymentCurrency
CAReversedAmtInTransCurrency
AmountInRefundCurrency
CAInterestAmtInPaymentCurrency
TransactionCurrency P_CAScrtyDepReqCalDocAmt TransactionCurrency Transaction Currency
PaymentCurrency PaidReleasedAmt PaymentCurrency Payment Currency
RefundCurrency ReturnAmount RefundCurrency
_TransactionCurrency _TransactionCurrency
_RefundCurrency _RefundCurrency
_PaymentCurrency _PaymentCurrency

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 P_CAScrtyDepReqCalculateAmount.
-- 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: PCALREQAMT

CREATE VIEW P_CAScrtyDepReqCalculateAmount AS
SELECT
  DocumentAmt.CASecurityDeposit AS CASecurityDeposit,
  DocumentAmt.CADocumentNumber AS CADocumentNumber,
  cast( coalesce(abs(DocumentAmt.CAAmountInTransactionCurrency), 0) as secdep_doc_amt_kk preserving type ) AS CAAmountInTransactionCurrency,
  cast( coalesce(abs(PayTransAmt.CAPaidAmountInTransCurrency), 0) as paid_kk ) AS CAPaidAmountInTransCurrency,
  cast( coalesce(abs(PaidReleasedAmt.CAPaymentAmountInPaytCurrency), 0) as paid_kk ) AS CAPaymentAmountInPaytCurrency,
  cast( coalesce(abs(PaidReleasedAmt.CAReleasedAmtInPaymentCurrency), 0) as rel_part_kk preserving type ) AS CAReleasedAmtInPaymentCurrency,
  cast( coalesce(abs(ReversedAmt.CAReversedAmtInTransCurrency), 0) as secdep_reversed_amt_kk preserving type ) AS CAReversedAmtInTransCurrency,
  cast( coalesce(abs(ReturnAmount.AmountInRefundCurrency), 0) as secdep_return_amt_kk ) AS AmountInRefundCurrency,
  cast( coalesce(abs(InterestAmt.CAInterestAmtInPaymentCurrency), 0) as sec_interest_kk ) AS CAInterestAmtInPaymentCurrency,
  DocumentAmt.TransactionCurrency AS TransactionCurrency,
  PaidReleasedAmt.PaymentCurrency AS PaymentCurrency,
  ReturnAmount.RefundCurrency AS RefundCurrency
FROM P_CAScrtyDepReqCalDocAmt AS DocumentAmt
LEFT OUTER JOIN I_Currency AS _TransactionCurrency ON TransactionCurrency = _TransactionCurrency.Currency  -- association [1..1]
LEFT OUTER JOIN I_Currency AS _RefundCurrency ON RefundCurrency = _RefundCurrency.Currency  -- association [1..1]
LEFT OUTER JOIN I_Currency AS _PaymentCurrency ON PaymentCurrency = _PaymentCurrency.Currency  -- association [1..1]
;