P_AllwdOrdTypPerSlsOrg

DDL: P_ALLWDORDTYPPERSLSORG SQL: PALWDORDTPSLSORG Type: view CONSUMPTION

P_AllwdOrdTypPerSlsOrg is a Consumption CDS View in SAP S/4HANA. It reads from 4 data sources (I_AllwdOrdTypPerSlsOrg, I_AllwdOrdTypPerSlsOrg, I_BillingDocument, I_SalesDocument) and exposes 12 fields with key field Document.

Data Sources (4)

SourceAliasJoin Type
I_AllwdOrdTypPerSlsOrg AllwdOrdTypPerSlsOrg left_outer
I_AllwdOrdTypPerSlsOrg AllwdOrdTypPerSlsOrg left_outer
I_BillingDocument BillingDocument union
I_SalesDocument SalesDocument from

Annotations (7)

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

Fields (12)

KeyFieldSource TableSource FieldDescription
KEY Document I_SalesDocument SalesDocument SD Document
SalesDocument I_SalesDocument SalesDocument SD Document
SalesDocumentType I_AllwdOrdTypPerSlsOrg SalesDocumentType Sales Doc. Type
SalesOrganization I_AllwdOrdTypPerSlsOrg SalesOrganization Sales Organization
Division I_AllwdOrdTypPerSlsOrg Division Internal Division ID
DistributionChannel I_AllwdOrdTypPerSlsOrg DistributionChannel RefDistCh-Cust/Mat.
BillingDocumentasDocument
SalesDocument I_BillingDocument BillingDocument SD Document
SalesDocumentType I_AllwdOrdTypPerSlsOrg SalesDocumentType Sales Doc. Type
SalesOrganization I_AllwdOrdTypPerSlsOrg SalesOrganization Sales Organization
Division I_AllwdOrdTypPerSlsOrg Division Internal Division ID
DistributionChannel I_AllwdOrdTypPerSlsOrg DistributionChannel RefDistCh-Cust/Mat.

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_AllwdOrdTypPerSlsOrg.
-- 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: PALWDORDTPSLSORG

CREATE VIEW P_AllwdOrdTypPerSlsOrg AS
SELECT
  SalesDocument.SalesDocument AS Document,
  SalesDocument.SalesDocument AS SalesDocument,
  AllwdOrdTypPerSlsOrg.SalesDocumentType AS SalesDocumentType,
  AllwdOrdTypPerSlsOrg.SalesOrganization AS SalesOrganization,
  AllwdOrdTypPerSlsOrg.Division AS Division,
  AllwdOrdTypPerSlsOrg.DistributionChannel AS DistributionChannel,
  case when AllwdTypPerSlsOrgCnt.AllwdOrdTypPerSlsOrgCount = 0 or AllwdTypPerSlsOrgCnt.AllwdOrdTypPerSlsOrgCount is null then '' else 'X' end as CheckRequired AS BillingDocumentasDocument
FROM I_SalesDocument AS SalesDocument
LEFT OUTER JOIN I_AllwdOrdTypPerSlsOrg AS AllwdOrdTypPerSlsOrg ON /* join condition not captured in parsed metadata */
-- UNION with additional select branch(es): I_BillingDocument
;