C_RETURNSREFERENCESALESORDER
Returns Reference Sales Order
C_RETURNSREFERENCESALESORDER is a CDS View in S/4HANA. Returns Reference Sales Order. It contains 5 fields. 1 CDS views read from this table.
CDS Views using this table (1)
| View | Type | Join | VDM | Description |
|---|---|---|---|---|
| C_RetsReferenceSalesOrderItem | view_entity | inner | CONSUMPTION | Returns Reference Sales Order Item |
Fields (5)
| Key | Field | CDS Fields | Used in Views |
|---|---|---|---|
| DistributionChannel | DistributionChannel | 1 | |
| OrganizationDivision | OrganizationDivision | 1 | |
| SalesDocumentType | SalesDocumentType | 1 | |
| SalesOrganization | SalesOrganization | 1 | |
| SDDocumentCategory | SDDocumentCategory | 1 |
@VDM.viewType: #CONSUMPTION
@AccessControl.authorizationCheck: #MANDATORY
@Metadata: {
allowExtensions: true,
ignorePropagatedAnnotations: true
}
@ObjectModel: {
semanticKey: ['SalesOrder'],
usageType: {
dataClass: #MIXED,
serviceQuality: #C,
sizeCategory: #XL
},
supportedCapabilities: [ #CDS_MODELING_ASSOCIATION_TARGET, #SQL_DATA_SOURCE, #CDS_MODELING_DATA_SOURCE ],
modelingPattern: #NONE
}
@Search.searchable: true
@EndUserText.label: 'Returns Reference Sales Order'
define view entity C_ReturnsReferenceSalesOrder
as select from I_SalesDocumentBasic as ReferenceDocument
association [0..*] to C_RetsReferenceSalesOrderItem as _ReferenceDocumentItem on $projection.SalesOrder = _ReferenceDocumentItem.ReferenceDocument
{
@Search.defaultSearchElement: true
key cast(ReferenceDocument.SalesDocument as vdm_sales_order preserving type) as SalesOrder,
ReferenceDocument.SalesDocumentType,
//Sold-To Party
@ObjectModel.text.element: [ 'SoldToPartyName' ]
ReferenceDocument.SoldToParty,
@Semantics.text: true
@ObjectModel.virtualElement: true
@ObjectModel.virtualElementCalculatedBy: 'ABAP:CL_SD_SLSORD_UI_PARTNER_UTIL'
cast('' as kunnr_ag) as SoldToPartyName,
//Total Amount
@Semantics.amount.currencyCode: 'TransactionCurrency'
ReferenceDocument.TotalNetAmount,
ReferenceDocument.TransactionCurrency,
ReferenceDocument.SDDocumentCategory,
// ACL
@Consumption.hidden:true
ReferenceDocument.SalesOrganization,
@Consumption.hidden:true
ReferenceDocument.DistributionChannel,
@Consumption.hidden:true
ReferenceDocument.OrganizationDivision,
// Association
_ReferenceDocumentItem
}
where
ReferenceDocument.SDDocumentCategory = 'C'
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_SALESDOCUMENTBASIC"
],
"ASSOCIATED":
[
"C_RETSREFERENCESALESORDERITEM"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/