P_RU_MONITOR_CONTRACTS

DDL: P_RU_MONITOR_CONTRACTS SQL: PRUMONCNT Type: view CONSUMPTION

Contracts

P_RU_MONITOR_CONTRACTS is a Consumption CDS View that provides data about "Contracts" in SAP S/4HANA. It reads from 1 data source (P_RU_MONITOR_CONTRACTS_DS) and exposes 28 fields with key fields CompanyCode, BusinessPartnerContract. It has 6 associations to related views.

Data Sources (1)

SourceAliasJoin Type
P_RU_MONITOR_CONTRACTS_DS Contracts from

Associations (6)

CardinalityTargetAliasCondition
[0..1] I_CompanyCode _CompanyCode Contracts.CompanyCode = _CompanyCode.CompanyCode
[0..1] I_Customer _Customer Contracts.Customer = _Customer.Customer
[0..1] I_Supplier _Supplier Contracts.Supplier = _Supplier.Supplier
[0..1] I_CustomerCompany _CustomerCompany Contracts.Customer = _CustomerCompany.Customer and Contracts.CompanyCode = _CustomerCompany.CompanyCode
[0..1] I_SupplierCompany _SupplierCompany Contracts.Supplier = _SupplierCompany.Supplier and Contracts.CompanyCode = _SupplierCompany.CompanyCode
[0..1] C_RU_MonitorContractValueHelpC _ContractsValueHelp Contracts.CompanyCode = _ContractsValueHelp.CompanyCode and Contracts.BusinessPartnerContract = _ContractsValueHelp.BusinessPartnerContract

Annotations (10)

NameValueLevelField
VDM.private true view
EndUserText.label Contracts view
VDM.viewType #CONSUMPTION view
AbapCatalog.sqlViewName PRUMONCNT view
AbapCatalog.compiler.compareFilter true view
ClientHandling.algorithm #SESSION_VARIABLE view
AccessControl.authorizationCheck #CHECK view
AbapCatalog.preserveKey true view
UI.headerInfo.typeName Contract view
UI.headerInfo.typeNamePlural Contracts view

Fields (28)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode CompanyCode Receiver Company Code
KEY BusinessPartnerContract P_RU_MONITOR_CONTRACTS_DS BusinessPartnerContract Int. Contract Number
BusinessPartnerContractExt P_RU_MONITOR_CONTRACTS_DS BusinessPartnerContractExt Ext. Contract Number
ContractStartDate P_RU_MONITOR_CONTRACTS_DS ContractStartDate Contract Start Date
ContractEndDate P_RU_MONITOR_CONTRACTS_DS ContractEndDate Contract End Date
CndnContrType ContractTp
Customer P_RU_MONITOR_CONTRACTS_DS Customer Sold-to Party
CustomerAccountGroup P_RU_MONITOR_CONTRACTS_DS CustomerAccountGroup Account group
CustomerAuthznGrp P_RU_MONITOR_CONTRACTS_DS CustomerAuthznGrp
CustomerIsBusPrpsCmpltd P_RU_MONITOR_CONTRACTS_DS CustomerIsBusPrpsCmpltd
CustomerCompanyAuthznGroup P_RU_MONITOR_CONTRACTS_DS CustomerCompanyAuthznGroup Authorization
CustCoIsBusPrpsCmpltd P_RU_MONITOR_CONTRACTS_DS CustCoIsBusPrpsCmpltd
Supplier P_RU_MONITOR_CONTRACTS_DS Supplier Supplier
SupplierAccountGroup P_RU_MONITOR_CONTRACTS_DS SupplierAccountGroup Account group
SupplierAuthznGrp P_RU_MONITOR_CONTRACTS_DS SupplierAuthznGrp Authorization
SupplierIsBusPrpsCmpltd P_RU_MONITOR_CONTRACTS_DS SupplierIsBusPrpsCmpltd
SupplierCompanyAuthznGroup P_RU_MONITOR_CONTRACTS_DS SupplierCompanyAuthznGroup
SuplrCoIsBusPrpsCmpltd P_RU_MONITOR_CONTRACTS_DS SuplrCoIsBusPrpsCmpltd Purpose Completed
CreatedByUser P_RU_MONITOR_CONTRACTS_DS CreatedByUser User Name
BPCustomerName
CompanyCodeName _CompanyCode CompanyCodeName Company Name
BPSupplierName
_CompanyCode _CompanyCode
_Supplier _Supplier
_Customer _Customer
_SupplierCompany _SupplierCompany
_CustomerCompany _CustomerCompany
_ContractsValueHelp _ContractsValueHelp

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_RU_MONITOR_CONTRACTS.
-- 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: PRUMONCNT

CREATE VIEW P_RU_MONITOR_CONTRACTS AS
SELECT
  CompanyCode,
  Contracts.BusinessPartnerContract AS BusinessPartnerContract,
  Contracts.BusinessPartnerContractExt AS BusinessPartnerContractExt,
  Contracts.ContractStartDate AS ContractStartDate,
  Contracts.ContractEndDate AS ContractEndDate,
  cast ( ContractType as wcb_contract_type) AS CndnContrType,
  Contracts.Customer AS Customer,
  Contracts.CustomerAccountGroup AS CustomerAccountGroup,
  Contracts.CustomerAuthznGrp AS CustomerAuthznGrp,
  Contracts.CustomerIsBusPrpsCmpltd AS CustomerIsBusPrpsCmpltd,
  Contracts.CustomerCompanyAuthznGroup AS CustomerCompanyAuthznGroup,
  Contracts.CustCoIsBusPrpsCmpltd AS CustCoIsBusPrpsCmpltd,
  Contracts.Supplier AS Supplier,
  Contracts.SupplierAccountGroup AS SupplierAccountGroup,
  Contracts.SupplierAuthznGrp AS SupplierAuthznGrp,
  Contracts.SupplierIsBusPrpsCmpltd AS SupplierIsBusPrpsCmpltd,
  Contracts.SupplierCompanyAuthznGroup AS SupplierCompanyAuthznGroup,
  Contracts.SuplrCoIsBusPrpsCmpltd AS SuplrCoIsBusPrpsCmpltd,
  Contracts.CreatedByUser AS CreatedByUser,
  _CustomerCompany._Customer.BPCustomerName AS BPCustomerName,
  _CompanyCode.CompanyCodeName AS CompanyCodeName,
  _SupplierCompany._Supplier.BPSupplierName AS BPSupplierName
FROM P_RU_MONITOR_CONTRACTS_DS AS Contracts
LEFT OUTER JOIN I_CompanyCode AS _CompanyCode ON Contracts.CompanyCode = _CompanyCode.CompanyCode  -- association [0..1]
LEFT OUTER JOIN I_Customer AS _Customer ON Contracts.Customer = _Customer.Customer  -- association [0..1]
LEFT OUTER JOIN I_Supplier AS _Supplier ON Contracts.Supplier = _Supplier.Supplier  -- association [0..1]
LEFT OUTER JOIN I_CustomerCompany AS _CustomerCompany ON Contracts.Customer = _CustomerCompany.Customer AND Contracts.CompanyCode = _CustomerCompany.CompanyCode  -- association [0..1]
LEFT OUTER JOIN I_SupplierCompany AS _SupplierCompany ON Contracts.Supplier = _SupplierCompany.Supplier AND Contracts.CompanyCode = _SupplierCompany.CompanyCode  -- association [0..1]
LEFT OUTER JOIN C_RU_MonitorContractValueHelpC AS _ContractsValueHelp ON Contracts.CompanyCode = _ContractsValueHelp.CompanyCode AND Contracts.BusinessPartnerContract = _ContractsValueHelp.BusinessPartnerContract  -- association [0..1]
;