C_RevenueFromInvoiceQry

DDL: C_REVENUEFROMINVOICEQRY Type: view CONSUMPTION

Sales Volume Flexible Analysis - Query

C_RevenueFromInvoiceQry is a Consumption CDS View that provides data about "Sales Volume Flexible Analysis - Query" in SAP S/4HANA. It reads from 1 data source (I_BillingDocumentItemCube) and exposes 151 fields with key fields BillingDocument, BillingDocumentItem.

Data Sources (1)

SourceAliasJoin Type
I_BillingDocumentItemCube I_BillingDocumentItemCube from

Parameters (2)

NameTypeDefault
P_ExchangeRateType kurst
P_DisplayCurrency vdm_v_display_currency

Annotations (13)

NameValueLevelField
ClientHandling.algorithm #SESSION_VARIABLE view
EndUserText.label Sales Volume Flexible Analysis - Query view
VDM.viewType #CONSUMPTION view
AccessControl.authorizationCheck #PRIVILEGED_ONLY view
AbapCatalog.preserveKey true view
AbapCatalog.sqlViewName CSDREVNFRMINVCQ view
AbapCatalog.compiler.compareFilter true view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.sizeCategory #XL view
Analytics.query true view
ObjectModel.modelingPattern #ANALYTICAL_QUERY view
OData.publish true view

Fields (151)

KeyFieldSource TableSource FieldDescription
KEY BillingDocument BillingDocument SD Document
KEY BillingDocumentItem BillingDocumentItem Item
SDDocumentCategory SDDocumentCategory Document Cat.
BillingDocumentType BillingDocumentType Billing Type
BillingDocumentCategory BillingDocumentCategory BillingCategory
SalesDocumentItemCategory SalesDocumentItemCategory Item Category
SalesDocumentItemType SalesDocumentItemType
ReturnItemProcessingType ReturnItemProcessingType Returns
DisplayCurrency
BaseUnit BaseUnit Unit of Measure
NetAmountInDisplayCurrency NetAmountInDisplayCurrency
SlsVolumeNetAmtInDspCrcy SlsVolumeNetAmtInDspCrcy
SalesVolumeQuantity SalesVolumeQuantity
CancldSlsVolumeNetAmtInDspCrcy CancldSlsVolumeNetAmtInDspCrcy
SlsProfitMargNetAmtInDspCrcy SlsProfitMargNetAmtInDspCrcy
CustCrdtMemoNetAmtInDspCrcy CustCrdtMemoNetAmtInDspCrcy
CustCrdtMemoPrftMargNetAmtInDC CustCrdtMemoPrftMargNetAmtInDC
NetSlsVolumeNetAmtInDC Net Sales Volume
NetSlsProfitMargNetAmtInDC Net Profit Margin
NetSalesCostAmountInDC Net Sales Cost
CreatedByUser CreatedByUser User Name
CreationDate CreationDate Time Stamp
CreationTime CreationTime Time of Change
LastChangeDate LastChangeDate Time Stamp
CreationDateYear CreationDateYear
CreationDateYearQuarter CreationDateYearQuarter
CreationDateYearMonth CreationDateYearMonth
BillingDocumentDateYear BillingDocumentDateYear
BillingDocDateYearQuarter BillingDocDateYearQuarter
BillingDocDateYearMonth BillingDocDateYearMonth
SalesOrganization SalesOrganization Sales Organization
DistributionChannel DistributionChannel RefDistCh-Cust/Mat.
OrganizationDivision OrganizationDivision Org. Division
Division Division Internal Division ID
SalesOffice SalesOffice Sales Office
SalesGroup SalesGroup Sales Group
PartnerCompany PartnerCompany Trading Partner
SoldToParty SoldToParty Sold-to Party
ShipToParty ShipToParty Ship-To Party (obsolete)
BillToParty BillToParty Inv. Recipient
PayerParty PayerParty Payer
SalesEmployee SalesEmployee Sales Employee
ResponsibleEmployee ResponsibleEmployee Employee Resp.
PurchaseOrderByCustomer PurchaseOrderByCustomer Purchase Order Number
CustomerRebateAgreement CustomerRebateAgreement
AdditionalCustomerGroup1 AdditionalCustomerGroup1 Customer Grp 1
AdditionalCustomerGroup2 AdditionalCustomerGroup2 Customer Grp 2
AdditionalCustomerGroup3 AdditionalCustomerGroup3 Customer Grp 3
AdditionalCustomerGroup4 AdditionalCustomerGroup4 Customer Grp 4
AdditionalCustomerGroup5 AdditionalCustomerGroup5 Customer Grp 5
SalesDistrict SalesDistrict Sales District
Country Country Venue: Ctry/Reg
Region Region Venue Region
CreditControlArea CreditControlArea Credit Control Area
SDDocumentReason SDDocumentReason Order Reason
RetailPromotion RetailPromotion Promotion
ItemIsRelevantForCredit ItemIsRelevantForCredit
SalesDeal SalesDeal
SalesPromotion SalesPromotion
Material Material Vehicle Model
Product Product Product Sold
Batch Batch Lot No.
ProductHierarchyNode ProductHierarchyNode Prod. Hierarchy
MaterialGroup MaterialGroup Product Group
ProductGroup ProductGroup Product Sold Group
MaterialCommissionGroup MaterialCommissionGroup
AdditionalMaterialGroup1 AdditionalMaterialGroup1 MaterialGroup 1
AdditionalMaterialGroup2 AdditionalMaterialGroup2 MaterialGroup 2
AdditionalMaterialGroup3 AdditionalMaterialGroup3 MaterialGroup 3
AdditionalMaterialGroup4 AdditionalMaterialGroup4 MaterialGroup 4
AdditionalMaterialGroup5 AdditionalMaterialGroup5 MaterialGroup 5
Plant Plant Valuation Area
StorageLocation StorageLocation StorageLocation
BillingDocumentItemText BillingDocumentItemText Item Descr.
BillingDocumentDate BillingDocumentDate Billing Date
CancelledBillingDocument CancelledBillingDocument Canceld Bill.Dc
BillingDocumentIsCancelled BillingDocumentIsCancelled Canceled
BillingQuantityUnit BillingQuantityUnit Sales Unit
BillingPlan BillingPlan Bill. Plan No.
BillingPlanItem BillingPlanItem Item
MainItemPricingRefMaterial MainItemPricingRefMaterial
AccountingDocument AccountingDocument Journal Entry
FiscalYear FiscalYear G/L Fiscal Year
FiscalPeriod FiscalPeriod Tax period
CompanyCode CompanyCode Receiver Company Code
CustomerAccountAssignmentGroup CustomerAccountAssignmentGroup AccAssmtGrpCust
AccountingExchangeRateIsSet AccountingExchangeRateIsSet
DocumentReferenceID DocumentReferenceID Reference
AssignmentReference AssignmentReference Assignment Reference
FixedValueDate FixedValueDate Fixed Val. Date
AdditionalValueDays AdditionalValueDays Add. Value Days
PaymentMethod PaymentMethod Pymt Meth.
CustomerProject CustomerProject Engmnt Project ID
DunningArea DunningArea Dunning Area
DunningKey DunningKey Dunning Key
DunningBlockingReason DunningBlockingReason Set Dunning Block
BusinessArea BusinessArea Business Area
CostCenter CostCenter Cost Center
ProfitCenter ProfitCenter Profit Center
WBSElement WBSElement WBS Internal ID
WBSElementInternalID WBSElementInternalID WBS Internal ID
WBSElementExternalID WBSElementExternalID WBS Element External ID
ProfitabilitySegment ProfitabilitySegment Profitability Segment
ProfitabilitySegment_2 ProfitabilitySegment_2 Profit. segment
OrderID OrderID Order ID
ControllingArea ControllingArea Controlling Area
PriceListType PriceListType Price List Tp.
CustomerGroup CustomerGroup Customer Group
CustomerPriceGroup CustomerPriceGroup CustPrice Group
PricingReferenceMaterial PricingReferenceMaterial Pr. Ref. Matl
VolumeRebateGroup VolumeRebateGroup Vol. Rebate Grp
CustomerPaymentTerms CustomerPaymentTerms Pyt Terms
IncotermsVersion IncotermsVersion Inco. Version
IncotermsClassification IncotermsClassification Incoterms
IncotermsTransferLocation IncotermsTransferLocation Incoterms 2
IncotermsLocation1 IncotermsLocation1 Inco. Location1
IncotermsLocation2 IncotermsLocation2 Inco. Location2
SDPricingProcedure SDPricingProcedure Pric. Procedure
PricingDate PricingDate Pricing Date
TaxDepartureCountry TaxDepartureCountry Tx Dep Ctry/Reg
VATRegistration VATRegistration VAT Registration No.
VATRegistrationCountry VATRegistrationCountry CtryRgnSlsTxNo.
VATRegistrationOrigin VATRegistrationOrigin OriginSlsTxNo.
CustomerTaxClassification1 CustomerTaxClassification1
CustomerTaxClassification2 CustomerTaxClassification2
CustomerTaxClassification3 CustomerTaxClassification3
CustomerTaxClassification4 CustomerTaxClassification4
CustomerTaxClassification5 CustomerTaxClassification5
CustomerTaxClassification6 CustomerTaxClassification6
CustomerTaxClassification7 CustomerTaxClassification7
CustomerTaxClassification8 CustomerTaxClassification8
CustomerTaxClassification9 CustomerTaxClassification9
ShippingCondition ShippingCondition Shipping Conditions
ShippingPoint ShippingPoint Shipping Point
ReferenceSDDocument ReferenceSDDocument Reference Doc.
ReferenceSDDocumentItem ReferenceSDDocumentItem Reference Item
ReferenceSDDocumentCategory ReferenceSDDocumentCategory Prec.Doc.Categ.
SalesDocument SalesDocument SD Document
SalesDocumentItem SalesDocumentItem Sales Document Item
SalesSDDocumentCategory SalesSDDocumentCategory Document Cat.
HigherLevelItem HigherLevelItem Higher-Lev.Item
PropagatePrftbltySgmt2BOM PropagatePrftbltySgmt2BOM
CostDeterminationIsRequired CostDeterminationIsRequired
OverallSDProcessStatus OverallSDProcessStatus
OverallBillingStatus OverallBillingStatus
AccountingPostingStatus AccountingPostingStatus
AccountingTransferStatus AccountingTransferStatus
BillingIssueType BillingIssueType
InvoiceListStatus InvoiceListStatus
OvrlItmGeneralIncompletionSts OvrlItmGeneralIncompletionSts
OverallPricingIncompletionSts OverallPricingIncompletionSts

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_RevenueFromInvoiceQry.
-- 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.
-- Parameters: P_ExchangeRateType : kurst, P_DisplayCurrency : vdm_v_display_currency

CREATE VIEW C_RevenueFromInvoiceQry AS
SELECT
  BillingDocument,
  BillingDocumentItem,
  SDDocumentCategory,
  BillingDocumentType,
  BillingDocumentCategory,
  SalesDocumentItemCategory,
  SalesDocumentItemType,
  ReturnItemProcessingType,
  cast(:P_DisplayCurrency as vdm_v_display_currency) AS DisplayCurrency,
  BaseUnit,
  NetAmountInDisplayCurrency,
  SlsVolumeNetAmtInDspCrcy,
  SalesVolumeQuantity,
  CancldSlsVolumeNetAmtInDspCrcy,
  SlsProfitMargNetAmtInDspCrcy,
  CustCrdtMemoNetAmtInDspCrcy,
  CustCrdtMemoPrftMargNetAmtInDC,
  cast (1 as net_sls_vol_net_amt_idc) AS NetSlsVolumeNetAmtInDC,
  cast (1 as net_prf_marg_net_amt_idc) AS NetSlsProfitMargNetAmtInDC,
  cast (1 as netsalescostamountindc) AS NetSalesCostAmountInDC,
  CreatedByUser,
  CreationDate,
  CreationTime,
  LastChangeDate,
  CreationDateYear,
  CreationDateYearQuarter,
  CreationDateYearMonth,
  BillingDocumentDateYear,
  BillingDocDateYearQuarter,
  BillingDocDateYearMonth,
  SalesOrganization,
  DistributionChannel,
  OrganizationDivision,
  Division,
  SalesOffice,
  SalesGroup,
  PartnerCompany,
  SoldToParty,
  ShipToParty,
  BillToParty,
  PayerParty,
  SalesEmployee,
  ResponsibleEmployee,
  PurchaseOrderByCustomer,
  CustomerRebateAgreement,
  AdditionalCustomerGroup1,
  AdditionalCustomerGroup2,
  AdditionalCustomerGroup3,
  AdditionalCustomerGroup4,
  AdditionalCustomerGroup5,
  SalesDistrict,
  Country,
  Region,
  CreditControlArea,
  SDDocumentReason,
  RetailPromotion,
  ItemIsRelevantForCredit,
  SalesDeal,
  SalesPromotion,
  Material,
  Product,
  Batch,
  ProductHierarchyNode,
  MaterialGroup,
  ProductGroup,
  MaterialCommissionGroup,
  AdditionalMaterialGroup1,
  AdditionalMaterialGroup2,
  AdditionalMaterialGroup3,
  AdditionalMaterialGroup4,
  AdditionalMaterialGroup5,
  Plant,
  StorageLocation,
  BillingDocumentItemText,
  BillingDocumentDate,
  CancelledBillingDocument,
  BillingDocumentIsCancelled,
  BillingQuantityUnit,
  BillingPlan,
  BillingPlanItem,
  MainItemPricingRefMaterial,
  AccountingDocument,
  FiscalYear,
  FiscalPeriod,
  CompanyCode,
  CustomerAccountAssignmentGroup,
  AccountingExchangeRateIsSet,
  DocumentReferenceID,
  AssignmentReference,
  FixedValueDate,
  AdditionalValueDays,
  PaymentMethod,
  CustomerProject,
  DunningArea,
  DunningKey,
  DunningBlockingReason,
  BusinessArea,
  CostCenter,
  ProfitCenter,
  WBSElement,
  WBSElementInternalID,
  WBSElementExternalID,
  ProfitabilitySegment,
  ProfitabilitySegment_2,
  OrderID,
  ControllingArea,
  PriceListType,
  CustomerGroup,
  CustomerPriceGroup,
  PricingReferenceMaterial,
  VolumeRebateGroup,
  CustomerPaymentTerms,
  IncotermsVersion,
  IncotermsClassification,
  IncotermsTransferLocation,
  IncotermsLocation1,
  IncotermsLocation2,
  SDPricingProcedure,
  PricingDate,
  TaxDepartureCountry,
  VATRegistration,
  VATRegistrationCountry,
  VATRegistrationOrigin,
  CustomerTaxClassification1,
  CustomerTaxClassification2,
  CustomerTaxClassification3,
  CustomerTaxClassification4,
  CustomerTaxClassification5,
  CustomerTaxClassification6,
  CustomerTaxClassification7,
  CustomerTaxClassification8,
  CustomerTaxClassification9,
  ShippingCondition,
  ShippingPoint,
  ReferenceSDDocument,
  ReferenceSDDocumentItem,
  ReferenceSDDocumentCategory,
  SalesDocument,
  SalesDocumentItem,
  SalesSDDocumentCategory,
  HigherLevelItem,
  PropagatePrftbltySgmt2BOM,
  CostDeterminationIsRequired,
  OverallSDProcessStatus,
  OverallBillingStatus,
  AccountingPostingStatus,
  AccountingTransferStatus,
  BillingIssueType,
  InvoiceListStatus,
  OvrlItmGeneralIncompletionSts,
  OverallPricingIncompletionSts
FROM I_BillingDocumentItemCube
;