I_CAValueAdjustmentReporting

DDL: I_CAVALUEADJUSTMENTREPORTING SQL: ICAVALADJMTRPTG Type: view COMPOSITE

Value adjustment reporting

I_CAValueAdjustmentReporting is a Composite CDS View that provides data about "Value adjustment reporting" in SAP S/4HANA. It reads from 1 data source (P_CAValueAdjustmentReporting) and exposes 42 fields with key fields CADocument, CARepetitionItemNumber, CABPItemNumber, CAPostingDate, CAValuationArea. It has 6 associations to related views.

Data Sources (1)

SourceAliasJoin Type
P_CAValueAdjustmentReporting P_CAValueAdjustmentReporting from

Parameters (1)

NameTypeDefault
P_CAApplicationArea applk_kk

Associations (6)

CardinalityTargetAliasCondition
[1..1] I_CompanyCode _CompCode $projection.CompanyCode = _CompCode.CompanyCode
[1..1] I_AdditionalCurrencyRoles _AddlCrcyRoles $projection.CompanyCode = _AddlCrcyRoles.CompanyCode and _AddlCrcyRoles.Ledger = '' and _AddlCrcyRoles.LedgerGroup = ''
[1..1] I_Currency _Currency $projection.DocumentCurrency = _Currency.Currency
[0..1] I_Currency _CompanyCodeCurrency $projection.CompanyCodeCurrency = _CompanyCodeCurrency.Currency
[0..1] I_Currency _AdditionalCurrency1 $projection.AdditionalCurrency1 = _AdditionalCurrency1.Currency
[0..1] I_Currency _AdditionalCurrency2 $projection.AdditionalCurrency2 = _AdditionalCurrency2.Currency

Annotations (9)

NameValueLevelField
AbapCatalog.sqlViewName ICAVALADJMTRPTG view
AbapCatalog.compiler.compareFilter true view
VDM.viewType #COMPOSITE view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #XXL view
ObjectModel.usageType.dataClass #CUSTOMIZING view
AccessControl.authorizationCheck #CHECK view
EndUserText.label Value adjustment reporting view
ClientHandling.algorithm #SESSION_VARIABLE view

Fields (42)

KeyFieldSource TableSource FieldDescription
KEY CADocument CADocument CA Document No.
KEY CARepetitionItemNumber CARepetitionItemNumber Repetition Item
KEY CABPItemNumber CABPItemNumber Item
KEY CAPostingDate CAPostingDate Posting Date
KEY CAValuationArea CAValuationArea
KEY CAValueAdjmtSequenceNumber CAValueAdjmtSequenceNumber
CompanyCode CompanyCode Receiver Company Code
BusinessPartner BusinessPartner Issuing Authority
CreditRiskClass CreditRiskClass Credit Risk Class
AccountingPrinciple AccountingPrinciple AP Ledger/CoCode
GLAccount GLAccount General Ledger
ProfitCenter ProfitCenter Profit Center
Segment Segment Segment number
Division Division Internal Division ID
CAAccountDeterminationCode CAAccountDeterminationCode Acct Determ. ID
CAMainTransaction CAMainTransaction Main Trans.
CASubTransaction CASubTransaction Subtransaction
GeneralLedgerAgingScope GeneralLedgerAgingScope Aging
GeneralLedgerAgingIncrement GeneralLedgerAgingIncrement Increment
DocumentCurrency DocumentCurrency Document Currency
CompanyCodeCurrency
AdditionalCurrency1
AdditionalCurrency2
CAAuthorizationGroup CAAuthorizationGroup AuthorizGroup
RealizedAmountIn1stCrcy
ChangeAmountIn1stCrcy
NewValueAdjmtAmtIn1stCrcy
ReleasedAmountIn1stCrcy
RealizedAmountIn2ndCrcy
ChangeAmountIn2ndCrcy
NewValueAdjmtAmtIn2ndCrcy
ReleasedAmountIn2ndCrcy
RealizedAmountIn3rdCrcy
ChangeAmountIn3rdCrcy
NewValueAdjmtAmtIn3rdCrcy
ReleasedAmountIn3rdCrcy
_CompCode _CompCode
_AddlCrcyRoles _AddlCrcyRoles
_Currency _Currency
_CompanyCodeCurrency _CompanyCodeCurrency
_AdditionalCurrency1 _AdditionalCurrency1
_AdditionalCurrency2 _AdditionalCurrency2

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 I_CAValueAdjustmentReporting.
-- 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: ICAVALADJMTRPTG
-- Parameters: P_CAApplicationArea : applk_kk

CREATE VIEW I_CAValueAdjustmentReporting AS
SELECT
  CADocument,
  CARepetitionItemNumber,
  CABPItemNumber,
  CAPostingDate,
  CAValuationArea,
  CAValueAdjmtSequenceNumber,
  CompanyCode,
  BusinessPartner,
  CreditRiskClass,
  AccountingPrinciple,
  GLAccount,
  ProfitCenter,
  Segment,
  Division,
  CAAccountDeterminationCode,
  CAMainTransaction,
  CASubTransaction,
  GeneralLedgerAgingScope,
  GeneralLedgerAgingIncrement,
  DocumentCurrency,
  cast(_CompCode.Currency as fis_hwaer preserving type) AS CompanyCodeCurrency,
  cast(_AddlCrcyRoles._AdditionalCrcyRole1Currency.Currency as fis_hwae2 preserving type) AS AdditionalCurrency1,
  cast(_AddlCrcyRoles._AdditionalCrcyRole2Currency.Currency as fis_hwae3 preserving type) AS AdditionalCurrency2,
  CAAuthorizationGroup,
  cast(RealizedAmountInDocCrcy * Currency1ExchangeRate as betrw_kk) AS RealizedAmountIn1stCrcy,
  cast(ChangeAmountInDocCrcy * Currency1ExchangeRate as betrw_kk) AS ChangeAmountIn1stCrcy,
  cast(NewValueAdjmtAmtInDocCrcy * Currency1ExchangeRate as betrw_kk) AS NewValueAdjmtAmtIn1stCrcy,
  cast(ReleasedAmountInDocCrcy * Currency1ExchangeRate as betrw_kk) AS ReleasedAmountIn1stCrcy,
  cast(RealizedAmountInDocCrcy * Currency2ExchangeRate as betrw_kk) AS RealizedAmountIn2ndCrcy,
  cast(ChangeAmountInDocCrcy * Currency2ExchangeRate as betrw_kk) AS ChangeAmountIn2ndCrcy,
  cast(NewValueAdjmtAmtInDocCrcy * Currency2ExchangeRate as betrw_kk) AS NewValueAdjmtAmtIn2ndCrcy,
  cast(ReleasedAmountInDocCrcy * Currency2ExchangeRate as betrw_kk) AS ReleasedAmountIn2ndCrcy,
  cast(RealizedAmountInDocCrcy * Currency3ExchangeRate as betrw_kk) AS RealizedAmountIn3rdCrcy,
  cast(ChangeAmountInDocCrcy * Currency3ExchangeRate as betrw_kk) AS ChangeAmountIn3rdCrcy,
  cast(NewValueAdjmtAmtInDocCrcy * Currency3ExchangeRate as betrw_kk) AS NewValueAdjmtAmtIn3rdCrcy,
  cast(ReleasedAmountInDocCrcy * Currency3ExchangeRate as betrw_kk) AS ReleasedAmountIn3rdCrcy
FROM P_CAValueAdjustmentReporting
LEFT OUTER JOIN I_CompanyCode AS _CompCode ON CompanyCode = _CompCode.CompanyCode  -- association [1..1]
LEFT OUTER JOIN I_AdditionalCurrencyRoles AS _AddlCrcyRoles ON CompanyCode = _AddlCrcyRoles.CompanyCode AND _AddlCrcyRoles.Ledger = '' AND _AddlCrcyRoles.LedgerGroup = ''  -- association [1..1]
LEFT OUTER JOIN I_Currency AS _Currency ON DocumentCurrency = _Currency.Currency  -- association [1..1]
LEFT OUTER JOIN I_Currency AS _CompanyCodeCurrency ON CompanyCodeCurrency = _CompanyCodeCurrency.Currency  -- association [0..1]
LEFT OUTER JOIN I_Currency AS _AdditionalCurrency1 ON AdditionalCurrency1 = _AdditionalCurrency1.Currency  -- association [0..1]
LEFT OUTER JOIN I_Currency AS _AdditionalCurrency2 ON AdditionalCurrency2 = _AdditionalCurrency2.Currency  -- association [0..1]
;