P_SupDmndOvwSDDateBasic
P_SupDmndOvwSDDateBasic is a Basic CDS View in SAP S/4HANA. It reads from 4 data sources (vbak, vbap, vbep, vbep) and exposes 15 fields.
Data Sources (4)
Annotations (9)
| Name | Value | Level | Field |
|---|---|---|---|
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| VDM.viewType | #BASIC | view | |
| VDM.private | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| AbapCatalog.sqlViewName | PSUPDMNDOVWSDDT1 | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ObjectModel.usageType.serviceQuality | #B | view | |
| ObjectModel.usageType.sizeCategory | #XXL | view |
Fields (15)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| RequirementDocumentNumber | vbep | vbeln | ||
| RequirementDocumentItem | vbep | posnr | ||
| EarliestReqdDelivDate | vbep | req_dlvdate | ||
| RequestedDate | vbep | mbdat | ||
| ProductAvailabilityDate | vbep | mbdat | ||
| Material | vbap | matnr | ||
| MaterialGroup | vbap | matkl | ||
| Plant | vbap | werks | ||
| SalesOrganization | vbak | vkorg | ||
| DistributionChannel | vbak | vtweg | ||
| Division | vbak | spart | ||
| ConfdOrderQtyByMatlAvailCheck | ||||
| DeliveredQuantityInBaseUnit | vbep | dlvqty_bu | ||
| ScheduleLine | vbep | etenr | ||
| ConfirmedDeliveryDate | vbep | edatu |
@ClientHandling.algorithm: #SESSION_VARIABLE
//@EndUserText.label: 'Basic View for Demand Date'
@VDM: {
viewType: #BASIC
}
@VDM.private: true
@AccessControl: {
authorizationCheck: #CHECK,
personalData.blocking: #('TRANSACTIONAL_DATA')
}
@AbapCatalog: {
sqlViewName: 'PSUPDMNDOVWSDDT1',
compiler.compareFilter: true
}
@ObjectModel: {
usageType: {
dataClass: #TRANSACTIONAL,
serviceQuality: #B,
sizeCategory: #XXL
}
}
define view P_SupDmndOvwSDDateBasic
as select from vbak as vbak
inner join vbap as vbap on vbak.vbeln = vbap.vbeln
inner join vbep as vbep on vbap.vbeln = vbep.vbeln
and vbap.posnr = vbep.posnr
inner join vbep as vbep1 on vbep.vbeln = vbep1.vbeln
and vbep.posnr = vbep1.posnr
and vbep.req_dlvdate = vbep1.req_dlvdate
and vbep1.wmeng > 0
and vbep1.rrqqty_bu > 0
{
vbep.vbeln as RequirementDocumentNumber,
vbep.posnr as RequirementDocumentItem,
vbep.req_dlvdate as EarliestReqdDelivDate,
vbep1.mbdat as RequestedDate,
vbep.mbdat as ProductAvailabilityDate,
vbap.matnr as Material,
vbap.matkl as MaterialGroup,
vbap.werks as Plant,
vbak.vkorg as SalesOrganization,
vbak.vtweg as DistributionChannel,
vbak.spart as Division,
case
when vbtyp = 'C' or vbtyp = 'I'
then
(
case
when vbep.umvkn != 0 and vbep.umvkn != vbep.umvkz
then cast( vbep.wmeng * division(vbep.umvkz,vbep.umvkn,3) as ovr_conf_so_sl_qty )
else cast( vbep.wmeng as ovr_conf_so_sl_qty )
end
)
when vbtyp = 'G'
then vbep.rrqqty_bu
else 0
end as ScheduleLineOrderQuantity,
case vbtyp when 'C' then vbep.lmeng when 'I' then vbep.lmeng when 'G' then vbep.crqqty_bu else 0 end as ConfdOrderQtyByMatlAvailCheck,
vbep.dlvqty_bu as DeliveredQuantityInBaseUnit,
vbep.etenr as ScheduleLine,
vbep.edatu as ConfirmedDeliveryDate
}
where
( vbep.bwart != '' or
vbak.vbtyp = 'G' )
and vbap.rfsta != 'C' //Reference Status != Completely processed
and vbap.posar != 'B' //Item Type != Text item
and vbap.lfsta != 'C' //Delivery Status != Completely processed
and vbap.abgru = ' ' //RejectionReason = ' '
and vbap.shkzg != 'X' //Returns != 'X'
and(
vbap.sobkz = ' '
or vbap.sobkz = 'E'
) //Consider Orders on Hand
and vbak.rfgsk != 'C' //Total Reference Status != Completely processed
and vbak.lfstk != 'C' //Total Delivery Status != Completely processed
and(
vbak.vbtyp = 'C' //Document Category = Order
or vbak.vbtyp = 'I' //Document Category = Order without Charge
or(
vbak.vbtyp = 'G' //Document Category = Contract
and vbak.fsh_cq_check = 'X' //Requirement Relevance for Contract = 'X'
)
)
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"VBAK",
"VBAP",
"VBEP"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/
Learn More
- What Is a CDS View in SAP S/4HANA?
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- CDS View Annotations — A Complete Guide
- CDS View Field Mapping and Associations
- Understanding the SAP S/4HANA Data Model
- CDS View Extensions and Custom Fields in SAP S/4HANA
- Released APIs and Stability Contracts in SAP S/4HANA