C_MassChangeSalesContract
Mass Change of Sales Contract
C_MassChangeSalesContract is a Consumption CDS View that provides data about "Mass Change of Sales Contract" in SAP S/4HANA. It reads from 1 data source (I_SalesDocument) and exposes 159 fields with key field SalesContract. It has 9 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_SalesDocument | SalesContract | from |
Associations (9)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_SDDocStandardPartner | _StandardPartner | $projection.SalesContract = _StandardPartner.SDDocument |
| [0..*] | I_SlsDocNonStdPartner | _NonStdPartner | $projection.SalesContract = _NonStdPartner.SDDocument |
| [1..*] | I_SDDocumentPartner | _SDDocumentPartner | $projection.SalesContract = _SDDocumentPartner.SDDocument |
| [0..*] | I_SalesDocumentItem | _SalesContractItem | $projection.SalesContract = _SalesContractItem.SalesDocument |
| [0..*] | C_SalesDocumentItemWl | _SalesDocumentItem | $projection.SalesContract = _SalesDocumentItem.SalesDocument |
| [0..*] | C_MassChgSalesDocumentItemWl | _MassChgSalesDocumentItemWl | $projection.SalesContract = _MassChgSalesDocumentItemWl.SalesDocument |
| [0..1] | E_SalesDocumentBasic | _Extension | $projection.SalesContract = _Extension.SalesDocument |
| [0..1] | C_SalesDocumentUserVH | _CreatedByUser | $projection.CreatedByUser = _CreatedByUser.UserID |
| [0..1] | C_SalesDocPaymentMethodVH | _PaymentMethod | $projection.PaymentMethod = _PaymentMethod.PaymentMethod and $projection.BillingCompanyCode = _PaymentMethod.BillingCompanyCode |
Annotations (19)
| Name | Value | Level | Field |
|---|---|---|---|
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| EndUserText.label | Mass Change of Sales Contract | view | |
| VDM.viewType | #CONSUMPTION | view | |
| VDM.lifecycle.contract.type | #PUBLIC_LOCAL_API | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| AccessControl.personalData.blocking | #REQUIRED | view | |
| AbapCatalog.preserveKey | true | view | |
| AbapCatalog.sqlViewName | CSDMCSLSCONTR | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| ObjectModel.compositionRoot | true | view | |
| ObjectModel.representativeKey | SalesContract | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.sizeCategory | #L | view | |
| Metadata.ignorePropagatedAnnotations | true | view | |
| Analytics.internalName | #LOCAL | view | |
| OData.entitySet.name | SlsContr | view | |
| Search.searchable | true | view | |
| Metadata.allowExtensions | true | view |
Fields (159)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | SalesContract | SD Document | ||
| SalesContractType | Sales Doc. Type | |||
| SDDocumentReason | SDDocumentReason | Order Reason | ||
| CreationDate | CreationDate | Time Stamp | ||
| CreatedByUser | CreatedByUser | User Name | ||
| SalesOrganization | SalesOrganization | Sales Organization | ||
| DistributionChannel | DistributionChannel | RefDistCh-Cust/Mat. | ||
| OrganizationDivision | Org. Division | |||
| SalesGroup | SalesGroup | Sales Group | ||
| SalesOffice | SalesOffice | Sales Office | ||
| SalesDistrict | SalesDistrict | Sales District | ||
| ShippingCondition | ShippingCondition | Shipping Conditions | ||
| HeaderIncotermsClassification | Incoterms | |||
| IncotermsLocation1 | IncotermsLocation1 | Inco. Location1 | ||
| IncotermsLocation2 | IncotermsLocation2 | Inco. Location2 | ||
| IncotermsVersion | IncotermsVersion | Inco. Version | ||
| ShippingType | ShippingType | Shipping Type | ||
| SoldToParty | SoldToParty | Sold-to Party | ||
| ShipToPartyName | ||||
| SoldToPartyName | ||||
| BillToPartyName | ||||
| PayerPartyName | ||||
| ResponsibleEmployeeName | ||||
| SalesEmployeeName | ||||
| OverallSDProcessStatus | OverallSDProcessStatus | |||
| SalesDocApprovalStatus | SalesDocApprovalStatus | |||
| OverallSDDocumentRejectionSts | ||||
| TotalBlockStatus | TotalBlockStatus | |||
| HdrGeneralIncompletionStatus | ||||
| HeaderBillgIncompletionStatus | ||||
| OverallPricingIncompletionSts | ||||
| OverallTrdCmplncEmbargoSts | ||||
| OvrlTrdCmplncSnctndListChkSts | ||||
| OvrlTrdCmplncLegalCtrlChkSts | ||||
| OverallChmlCmplncStatus | ||||
| OverallDangerousGoodsStatus | ||||
| ContractDownPaymentStatus | ||||
| SalesContractValidityStartDate | AgrmtValdtyStartDate | |||
| SalesContractValidityEndDate | AgrmtValdtyEndDate | |||
| TotalNetAmount | TotalNetAmount | Total Net Amount | ||
| TransactionCurrency | TransactionCurrency | Transaction Currency | ||
| BusinessArea | BusinessArea | Business Area | ||
| CostCenter | CostCenter | Cost Center | ||
| ControllingArea | ControllingArea | Controlling Area | ||
| BillingCompanyCode | BillingCompanyCode | CCodeToBeBilled | ||
| PricingDate | PricingDate | Pricing Date | ||
| CustomerPurchaseOrderDate | CustomerPurchaseOrderDate | Purchase Order Date | ||
| PurchaseOrderByCustomer | PurchaseOrderByCustomer | Purchase Order Number | ||
| SalesContractDate | SalesDocumentDate | Document Date | ||
| CreditControlArea | CreditControlArea | Credit Control Area | ||
| CustomerGroup | CustomerGroup | Customer Group | ||
| 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 | ||
| SalesContractApprovalReason | ||||
| CustomerPaymentTerms | Pyt Terms | |||
| PaymentMethod | PaymentMethod | Pymt Meth. | ||
| MasterSalesContract | MasterSalesContract | |||
| AdditionalPartnerName | ||||
| Product | ||||
| PartnerFunction | ||||
| Customer | ||||
| Supplier | ||||
| Personnel | ||||
| ContactPerson | ||||
| SlsDocMassChangeRequestUUID | ||||
| SlsDocMassChgEntityLevel | ||||
| Division | ||||
| SalesContractItemCategory | ||||
| SalesDocumentRjcnReason | ||||
| BillingDocumentDate | ||||
| Plant | ||||
| ProfitCenter | ||||
| DeliveryPriority | ||||
| SDProcessStatus | ||||
| SDDocumentRejectionStatus | ||||
| ItemGeneralIncompletionStatus | ||||
| ItemBillingIncompletionStatus | ||||
| PricingIncompletionStatus | ||||
| ItemDeliveryIncompletionStatus | ||||
| SDDocReferenceStatus | ||||
| TotalSDDocReferenceStatus | ||||
| TrdCmplncEmbargoSts | ||||
| TrdCmplncSnctndListChkSts | ||||
| ChmlCmplncStatus | ||||
| DangerousGoodsStatus | ||||
| ContractItemDownPaymentStatus | ||||
| PaymentTerms | ||||
| IncotermsClassification | ||||
| SalesDocumentType | SalesDocumentType | Sales Doc. Type | ||
| SDDocumentCategory | SDDocumentCategory | Document Cat. | ||
| SDDocumentReasonText | ||||
| SalesGroupName | ||||
| SalesOfficeName | ||||
| SalesDistrictName | ||||
| ShippingConditionName | ||||
| CustomerPaymentTermsName | ||||
| IncotermsClassificationName | ||||
| CurrencyName | ||||
| _SalesContractItem | _SalesContractItem | |||
| _SalesDocumentItem | _SalesDocumentItem | |||
| _MassChgSalesDocumentItemWl | _MassChgSalesDocumentItemWl | |||
| _CreatedByUser | _CreatedByUser | |||
| _PaymentMethod | _PaymentMethod | |||
| _SalesOrganization | _SalesOrganization | |||
| _DistributionChannel | _DistributionChannel | |||
| _OrganizationDivision | _OrganizationDivision | |||
| _SalesGroup | _SalesGroup | |||
| _SalesOffice | _SalesOffice | |||
| _CustomerGroup | _CustomerGroup | |||
| _AdditionalCustomerGroup1 | _AdditionalCustomerGroup1 | |||
| _AdditionalCustomerGroup2 | _AdditionalCustomerGroup2 | |||
| _AdditionalCustomerGroup3 | _AdditionalCustomerGroup3 | |||
| _AdditionalCustomerGroup4 | _AdditionalCustomerGroup4 | |||
| _AdditionalCustomerGroup5 | _AdditionalCustomerGroup5 | |||
| _CreditControlArea | _CreditControlArea | |||
| _SDDocumentReason | _SDDocumentReason | |||
| _SalesDistrict | _SalesDistrict | |||
| _TransactionCurrency | _TransactionCurrency | |||
| _ShippingType | _ShippingType | |||
| _ShippingCondition | _ShippingCondition | |||
| _IncotermsClassification | _IncotermsClassification | |||
| _IncotermsVersion | _IncotermsVersion | |||
| _BillingCompanyCode | _BillingCompanyCode | |||
| _CustomerPaymentTerms | _CustomerPaymentTerms | |||
| _BusinessArea | _BusinessArea | |||
| _CostCenter | _CostCenter | |||
| _ControllingArea | _ControllingArea | |||
| _OverallSDProcessStatus | _OverallSDProcessStatus | |||
| _SalesDocApprovalStatus | _SalesDocApprovalStatus | |||
| _OverallSDDocumentRejectionSts | _OverallSDDocumentRejectionSts | |||
| _TotalBlockStatus | _TotalBlockStatus | |||
| _HdrGeneralIncompletionStatus | _HdrGeneralIncompletionStatus | |||
| _OverallPricingIncompletionSts | _OverallPricingIncompletionSts | |||
| _HeaderBillgIncompletionStatus | _HeaderBillgIncompletionStatus | |||
| _OverallChmlCmplncStatus | _OverallChmlCmplncStatus | |||
| _OverallDangerousGoodsStatus | _OverallDangerousGoodsStatus | |||
| _DownPaymentStatus | _DownPaymentStatus | |||
| _OvrlTradeCmplncEmbargoStatus | _OvrlTradeCmplncEmbargoStatus | |||
| _OvTrdCmplncSnctndListChkSts | _OvTrdCmplncSnctndListChkSts | |||
| _OvrlTrdCmplncLegalCtrlChkSts | _OvrlTrdCmplncLegalCtrlChkSts | |||
| _NonStdPartner | _NonStdPartner | |||
| _SoldToParty | _SoldToParty | |||
| _SDDocumentPartner | _SDDocumentPartner | |||
| _SalesDocumentType | _SalesDocumentType | |||
| OrganizationBPName1 | _SoldToParty | OrganizationBPName1 | Name 1 | |
| OrganizationBPName2 | _SoldToParty | OrganizationBPName2 | Name 2 | |
| ShipToParty | _StandardPartner | ShipToParty | Ship-To Party (obsolete) | |
| PayerParty | _StandardPartner | PayerParty | Payer | |
| BillToParty | _StandardPartner | BillToParty | Inv. Recipient | |
| ResponsibleEmployee | _StandardPartner | ResponsibleEmployee | Employee Resp. | |
| SalesEmployee | _StandardPartner | SalesEmployee | Sales Employee | |
| _ShipToParty | _StandardPartner | _ShipToParty | ||
| _PayerParty | _StandardPartner | _PayerParty | ||
| _BillToParty | _StandardPartner | _BillToParty | ||
| _ResponsibleEmployee | _StandardPartner | _ResponsibleEmployee | ||
| _SalesEmployee | _StandardPartner | _SalesEmployee |
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_MassChangeSalesContract.
-- 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.
CREATE VIEW C_MassChangeSalesContract AS
SELECT
cast(SalesDocument as sales_contract preserving type) AS SalesContract,
cast( SalesDocumentType as sales_contract_type preserving type ) AS SalesContractType,
SDDocumentReason,
CreationDate,
CreatedByUser,
SalesOrganization,
DistributionChannel,
cast( OrganizationDivision as organization_division preserving type ) AS OrganizationDivision,
SalesGroup,
SalesOffice,
SalesDistrict,
ShippingCondition,
cast( IncotermsClassification as vdm_header_incoterm1 preserving type ) AS HeaderIncotermsClassification,
IncotermsLocation1,
IncotermsLocation2,
IncotermsVersion,
ShippingType,
SoldToParty,
cast('' as ad_namtext ) AS ShipToPartyName,
cast('' as ad_namtext ) AS SoldToPartyName,
cast('' as ad_namtext ) AS BillToPartyName,
cast('' as ad_namtext ) AS PayerPartyName,
cast('' as ad_namtext ) AS ResponsibleEmployeeName,
cast('' as ad_namtext ) AS SalesEmployeeName,
OverallSDProcessStatus,
SalesDocApprovalStatus,
cast(OverallSDDocumentRejectionSts as ovrl_sd_doc_rejection_status preserving type ) AS OverallSDDocumentRejectionSts,
TotalBlockStatus,
cast(HdrGeneralIncompletionStatus as hdr_general_incompltn_status preserving type ) AS HdrGeneralIncompletionStatus,
cast(HeaderBillgIncompletionStatus as hdrbillgincompletionstatus preserving type ) AS HeaderBillgIncompletionStatus,
cast(OverallPricingIncompletionSts as ovrl_pricing_incompletion_sts preserving type ) AS OverallPricingIncompletionSts,
cast(OverallTrdCmplncEmbargoSts as overall_embargo_status preserving type ) AS OverallTrdCmplncEmbargoSts,
cast(OvrlTrdCmplncSnctndListChkSts as ovrl_watchlist_screening_sts preserving type ) AS OvrlTrdCmplncSnctndListChkSts,
cast(OvrlTrdCmplncLegalCtrlChkSts as overall_legal_control_status preserving type ) AS OvrlTrdCmplncLegalCtrlChkSts,
cast(OverallChmlCmplncStatus as ovrl_product_marketability_sts preserving type ) AS OverallChmlCmplncStatus,
cast(OverallDangerousGoodsStatus as overall_dangerous_goods_status preserving type ) AS OverallDangerousGoodsStatus,
cast(ContractDownPaymentStatus as hdr_down_payment_status preserving type) AS ContractDownPaymentStatus,
AgrmtValdtyStartDate AS SalesContractValidityStartDate,
AgrmtValdtyEndDate AS SalesContractValidityEndDate,
TotalNetAmount,
TransactionCurrency,
BusinessArea,
CostCenter,
ControllingArea,
BillingCompanyCode,
PricingDate,
CustomerPurchaseOrderDate,
PurchaseOrderByCustomer,
SalesDocumentDate AS SalesContractDate,
CreditControlArea,
CustomerGroup,
AdditionalCustomerGroup1,
AdditionalCustomerGroup2,
AdditionalCustomerGroup3,
AdditionalCustomerGroup4,
AdditionalCustomerGroup5,
cast( SalesDocApprovalReason as sd_apm_approval_reason_vdm preserving type ) AS SalesContractApprovalReason,
cast( CustomerPaymentTerms as hdr_dzterm preserving type ) AS CustomerPaymentTerms,
PaymentMethod,
MasterSalesContract,
cast( ' ' as abap.char( 100 )) AS AdditionalPartnerName,
cast( ' ' as productnumber ) AS Product,
cast( ' ' as parvw_unv preserving type ) AS PartnerFunction,
cast( ' ' as kunnr) AS Customer,
cast( ' ' as lifnr) AS Supplier,
cast( '00000000' as pernr_d) AS Personnel,
cast( '0000000000' as parnr) AS ContactPerson,
hextobin( '00000000000000000000000000000000' ) AS SlsDocMassChangeRequestUUID,
cast ('H' as sd_mcc_entity_level) AS SlsDocMassChgEntityLevel,
cast( '' as spart ) AS Division,
cast( '' as pstyv ) AS SalesContractItemCategory,
cast( ' ' as abgru_va preserving type ) AS SalesDocumentRjcnReason,
cast( '00000000' as fkdat ) AS BillingDocumentDate,
cast( '' as werks_ext ) AS Plant,
cast( ' ' as prctr ) AS ProfitCenter,
cast( '00' as lprio ) AS DeliveryPriority,
cast( '' as gbsta preserving type ) AS SDProcessStatus,
cast( ' ' as absta_vb preserving type ) AS SDDocumentRejectionStatus,
cast( ' ' as general_item_incompletion_sts preserving type ) AS ItemGeneralIncompletionStatus,
cast( ' ' as itms_incompltn_sts_billg preserving type ) AS ItemBillingIncompletionStatus,
cast( ' ' as pricing_incompletion_status preserving type ) AS PricingIncompletionStatus,
cast( ' ' as itm_deliv_incompletion_status preserving type ) AS ItemDeliveryIncompletionStatus,
cast( ' ' as rfsta preserving type ) AS SDDocReferenceStatus,
cast( ' ' as rfgsa preserving type ) AS TotalSDDocReferenceStatus,
cast('' as embargochksts preserving type ) AS TrdCmplncEmbargoSts,
cast('' as watchlistscrngchksts preserving type ) AS TrdCmplncSnctndListChkSts,
cast('' as mon_tdd_pcsta preserving type ) AS ChmlCmplncStatus,
cast('' as mon_tdd_dgsta preserving type ) AS DangerousGoodsStatus,
cast('' as dp_clear_sta preserving type ) AS ContractItemDownPaymentStatus,
cast('' as abap.char(4) ) AS PaymentTerms,
cast(' ' as inco1 preserving type) AS IncotermsClassification,
SalesDocumentType,
SDDocumentCategory,
SalesContract._SDDocumentReason._Text[1:Language = $session.system_language].SDDocumentReasonText AS SDDocumentReasonText,
SalesContract._SalesGroup._Text[1:Language = $session.system_language].SalesGroupName AS SalesGroupName,
SalesContract._SalesOffice._Text[1:Language = $session.system_language].SalesOfficeName AS SalesOfficeName,
SalesContract._SalesDistrict._Text[1:Language = $session.system_language].SalesDistrictName AS SalesDistrictName,
SalesContract._ShippingCondition._Text[1:Language = $session.system_language].ShippingConditionName AS ShippingConditionName,
SalesContract._CustomerPaymentTerms._Text[1:Language = $session.system_language].CustomerPaymentTermsName AS CustomerPaymentTermsName,
SalesContract._IncotermsClassification._Text[1:Language = $session.system_language].IncotermsClassificationName AS IncotermsClassificationName,
SalesContract._TransactionCurrency._Text[1:Language = $session.system_language].CurrencyName AS CurrencyName,
_SoldToParty.OrganizationBPName1 AS OrganizationBPName1,
_SoldToParty.OrganizationBPName2 AS OrganizationBPName2,
_StandardPartner.ShipToParty AS ShipToParty,
_StandardPartner.PayerParty AS PayerParty,
_StandardPartner.BillToParty AS BillToParty,
_StandardPartner.ResponsibleEmployee AS ResponsibleEmployee,
_StandardPartner.SalesEmployee AS SalesEmployee,
_StandardPartner._ShipToParty AS _ShipToParty,
_StandardPartner._PayerParty AS _PayerParty,
_StandardPartner._BillToParty AS _BillToParty,
_StandardPartner._ResponsibleEmployee AS _ResponsibleEmployee,
_StandardPartner._SalesEmployee AS _SalesEmployee
FROM I_SalesDocument AS SalesContract
LEFT OUTER JOIN I_SDDocStandardPartner AS _StandardPartner ON SalesContract = _StandardPartner.SDDocument -- association [0..1]
LEFT OUTER JOIN I_SlsDocNonStdPartner AS _NonStdPartner ON SalesContract = _NonStdPartner.SDDocument -- association [0..*]
LEFT OUTER JOIN I_SDDocumentPartner AS _SDDocumentPartner ON SalesContract = _SDDocumentPartner.SDDocument -- association [1..*]
LEFT OUTER JOIN I_SalesDocumentItem AS _SalesContractItem ON SalesContract = _SalesContractItem.SalesDocument -- association [0..*]
LEFT OUTER JOIN C_SalesDocumentItemWl AS _SalesDocumentItem ON SalesContract = _SalesDocumentItem.SalesDocument -- association [0..*]
LEFT OUTER JOIN C_MassChgSalesDocumentItemWl AS _MassChgSalesDocumentItemWl ON SalesContract = _MassChgSalesDocumentItemWl.SalesDocument -- association [0..*]
LEFT OUTER JOIN E_SalesDocumentBasic AS _Extension ON SalesContract = _Extension.SalesDocument -- association [0..1]
LEFT OUTER JOIN C_SalesDocumentUserVH AS _CreatedByUser ON CreatedByUser = _CreatedByUser.UserID -- association [0..1]
LEFT OUTER JOIN C_SalesDocPaymentMethodVH AS _PaymentMethod ON PaymentMethod = _PaymentMethod.PaymentMethod AND BillingCompanyCode = _PaymentMethod.BillingCompanyCode -- association [0..1]
;
Learn More
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- 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
- BSEG to ACDOCA: The Universal Journal Migration
- Business Partner Migration: KNA1/LFA1 to BUT000
- Material Document Migration: MSEG/MKPF to MATDOC
- How to Find the Right CDS View for an SAP Table
- BW Extractor to CDS View Migration Guide
- S/4HANA CDS View Deprecation: What You Need to Know
- ABAP CDS View Tutorial — From Basics to Real-World Examples
- RAP and CDS Views — Building Transactional Apps in SAP S/4HANA
- Sales Document Status Migration: VBUP/VBUK Removal in S/4HANA
- CO Tables in S/4HANA: COEP, COBK, COSS, COSP to ACDOCA