C_ExciseDueDocument

DDL: C_EXCISEDUEDOCUMENT SQL: CSDEXDUEDOC Type: view CONSUMPTION Package: GLO_LOG_IN

Excise Duelist from Billing Document

C_ExciseDueDocument is a Consumption CDS View (Dimension) that provides data about "Excise Duelist from Billing Document" in SAP S/4HANA. It reads from 1 data source (P_ExciseDutyDefnMerge) and exposes 35 fields with key field BillingDocument. It has 7 associations to related views. Part of development package GLO_LOG_IN.

Data Sources (1)

SourceAliasJoin Type
P_ExciseDutyDefnMerge P_ExciseDutyDefnMerge left_outer

Associations (7)

CardinalityTargetAliasCondition
[1..*] C_ExciseDueDocItem _ExciseDueItem $projection.BillingDocument = _ExciseDueItem.BillingDocument
[0..1] I_Currency _TransactionCurrency $projection.TransactionCurrency = _TransactionCurrency.Currency
[1..1] I_CompanyCode _CompanyCode $projection.CompanyCode = _CompanyCode.CompanyCode
[1..1] I_CompanyCodeStdVH _CompanyCodeStdVH $projection.CompanyCode = _CompanyCodeStdVH.CompanyCode
[0..1] I_DistributionChannel _DistributionChannel $projection.DistributionChannel = _DistributionChannel.DistributionChannel
[0..1] I_Division _Division $projection.Division = _Division.Division
[0..1] I_SalesOrganization _SalesOrganization $projection.SalesOrganization = _SalesOrganization.SalesOrganization

Annotations (14)

NameValueLevelField
EndUserText.label Excise Duelist from Billing Document view
ObjectModel.representativeKey BillingDocument view
AbapCatalog.sqlViewName CSDEXDUEDOC view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #CHECK view
AccessControl.personalData.blocking #NOT_REQUIRED view
VDM.viewType #CONSUMPTION view
ClientHandling.algorithm #SESSION_VARIABLE view
Metadata.allowExtensions true view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.dataClass #MIXED view
Analytics.dataCategory #DIMENSION view
Analytics.dataExtraction.enabled true view

Fields (35)

KeyFieldSource TableSource FieldDescription
KEY BillingDocument I_ExciseDueDocHdr BillingDocument
BillingDocumentItem I_ExciseDueDocHdr BillingDocumentItem
SalesOrganization I_ExciseDueDocHdr SalesOrganization
DistributionChannel I_ExciseDueDocHdr DistributionChannel
Division I_ExciseDueDocHdr Division
BillingDocumentCategory I_ExciseDueDocHdr BillingDocumentCategory
SoldToParty I_ExciseDueDocHdr SoldToParty
BillingDocumentDate I_ExciseDueDocHdr BillingDocumentDate
TransactionCurrency I_ExciseDueDocHdr TransactionCurrency
ExciseDocStatus I_ExciseDueDocHdr ExciseDocStatus
ShippingPoint I_ExciseDueDocHdr ShippingPoint
CompanyCode I_ExciseDueDocHdr CompanyCode
Plant I_ExciseDueDocHdr Plant
PlantName I_ExciseDueDocHdr PlantName
PricingDocument I_ExciseDueDocHdr PricingDocument
TaxCalculationProcedure I_ExciseDueDocHdr TaxCalculationProcedure
SDPricingProcedure I_ExciseDueDocHdr SDPricingProcedure
Currency I_ExciseDueDocHdr Currency
AEDAmountendasAEDAmount
BEDAmountendasBEDAmount
SEDAmountendasSEDAmount
NCCDAmountendasNCCDAmount
CESSAmountendasCESSAmount
ECSAmountendasECSAmount
_BillingDocumentCategory I_ExciseDueDocHdr _BillingDocumentCategory
_Item I_ExciseDueDocHdr _Item
_ExciseDueItem _ExciseDueItem
_CompanyCode _CompanyCode
_CompanyCodeStdVH _CompanyCodeStdVH
_Division _Division
_DistributionChannel _DistributionChannel
_TransactionCurrency _TransactionCurrency
_SalesOrganization _SalesOrganization
_ExciseSeriesGrpDtmn _ExciseSeriesGrpDtmn
_Partner _Partner
@EndUserText.label: 'Excise Duelist from Billing Document'
@ObjectModel.representativeKey: 'BillingDocument'
@AbapCatalog.sqlViewName: 'CSDEXDUEDOC'
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #CHECK
@AccessControl.personalData.blocking: #NOT_REQUIRED
@VDM.viewType: #CONSUMPTION
@ClientHandling.algorithm: #SESSION_VARIABLE
@Metadata.allowExtensions:true
@ObjectModel.usageType.serviceQuality:#D
@ObjectModel.usageType.sizeCategory: #XL
@ObjectModel.usageType.dataClass: #MIXED

@Analytics:{
dataCategory:#DIMENSION , dataExtraction.enabled:true }

define view C_ExciseDueDocument
  as select distinct from I_ExciseDueDocHdr
    left outer join       P_ExciseDutyDefnMerge on I_ExciseDueDocHdr.BillingDocument = P_ExciseDutyDefnMerge.BillingDocument

  association [1..*] to C_ExciseDueDocItem    as _ExciseDueItem       on $projection.BillingDocument = _ExciseDueItem.BillingDocument
  association [0..1] to I_Currency            as _TransactionCurrency on $projection.TransactionCurrency = _TransactionCurrency.Currency
  association [1..1] to I_CompanyCode         as _CompanyCode         on $projection.CompanyCode = _CompanyCode.CompanyCode
  association [1..1] to I_CompanyCodeStdVH    as _CompanyCodeStdVH         on $projection.CompanyCode = _CompanyCodeStdVH.CompanyCode
  association [0..1] to I_DistributionChannel as _DistributionChannel on $projection.DistributionChannel = _DistributionChannel.DistributionChannel
  association [0..1] to I_Division            as _Division            on $projection.Division = _Division.Division
  association [0..1] to I_SalesOrganization   as _SalesOrganization   on $projection.SalesOrganization = _SalesOrganization.SalesOrganization
  /*association [0..1] to I_ExciseSeriesGrpDetrmn as _ExciseSeriesGrpDtmn on  $projection.SalesOrganization   = _ExciseSeriesGrpDtmn.SalesOrganization
                                                                        and $projection.DistributionChannel = _ExciseSeriesGrpDtmn.DistributionChannel
                                                                        and $projection.Division            = _ExciseSeriesGrpDtmn.Division
                                                                        and $projection.ShippingPoint       = _ExciseSeriesGrpDtmn.ShippingPoint*/

{
  key I_ExciseDueDocHdr.BillingDocument,
      I_ExciseDueDocHdr.BillingDocumentItem,
      @ObjectModel.foreignKey.association: '_SalesOrganization'
      I_ExciseDueDocHdr.SalesOrganization,
      @ObjectModel.foreignKey.association: '_DistributionChannel'
      I_ExciseDueDocHdr.DistributionChannel,
      @ObjectModel.foreignKey.association: '_Division'
      I_ExciseDueDocHdr.Division,
      I_ExciseDueDocHdr.BillingDocumentCategory,
      I_ExciseDueDocHdr.SoldToParty,
      //I_ExciseDueDocHdr.BaseUnit,

      I_ExciseDueDocHdr.BillingDocumentDate,
      @ObjectModel.foreignKey.association: '_TransactionCurrency'
      I_ExciseDueDocHdr.TransactionCurrency,
      I_ExciseDueDocHdr.ExciseDocStatus,
      I_ExciseDueDocHdr.ShippingPoint,
      I_ExciseDueDocHdr.CompanyCode,
      I_ExciseDueDocHdr.Plant,
      I_ExciseDueDocHdr.PlantName,
      I_ExciseDueDocHdr.PricingDocument,
      I_ExciseDueDocHdr.TaxCalculationProcedure,
      I_ExciseDueDocHdr.SDPricingProcedure,
      @Semantics.currencyCode: true
      I_ExciseDueDocHdr.Currency,
      //I_ExciseDueDocHdr.DeliveryDocument,

      //substring( cast( tstmp_current_utctimestamp() as abap.char(17) ), 1, 8 ) as PostingDate,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.AEDAmount,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.AEDAmount
      end                                                                      as AEDAmount,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.BEDAmount,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.BEDAmount
      end                                                                      as BEDAmount,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.SEDAmount,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.SEDAmount
      end                                                                      as SEDAmount,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.NCCDAmount,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.NCCDAmount
      end                                                                      as NCCDAmount,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.CESSAmount,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.CESSAmount
      end                                                                      as CESSAmount,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.ECSAmount,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.ECSAmount
      end                                                                      as ECSAmount,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.AdditionalTax1Value,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.AdditionalTax1Value
      end                                                                      as AdditionalTax1Value,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.AdditionalTax2Value,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.AdditionalTax2Value
      end                                                                      as AdditionalTax2Value,

      @Semantics.amount.currencyCode: 'Currency'
      case
      when TransactionCurrency != Currency  then
      currency_conversion( amount => P_ExciseDutyDefnMerge.AdditionalTax3Value,
                           source_currency => I_ExciseDueDocHdr.TransactionCurrency,
                           target_currency => I_ExciseDueDocHdr.Currency,
                           exchange_rate_date => I_ExciseDueDocHdr.PricingDate)
      else
      P_ExciseDutyDefnMerge.AdditionalTax3Value
      end                                                                      as AdditionalTax3Value,


      /* Associations */
      I_ExciseDueDocHdr._BillingDocumentCategory,
      I_ExciseDueDocHdr._Item,
      _ExciseDueItem,
      _CompanyCode,
      _CompanyCodeStdVH,
      _Division,
      _DistributionChannel,
      _TransactionCurrency,
      _SalesOrganization,
      _ExciseSeriesGrpDtmn,
      _Partner
}