@EndUserText.label: 'Transportation Order Item Analytics'
@ClientHandling.algorithm: #SESSION_VARIABLE
@Metadata: {allowExtensions: true,
ignorePropagatedAnnotations: true}
@AbapCatalog: {sqlViewName: 'ITRANSPORDITMANA',
compiler.compareFilter: true,
buffering: {status: #NOT_ALLOWED}}
@AccessControl: {authorizationCheck: #CHECK,
personalData.blocking: #('TRANSACTIONAL_DATA')}
@ObjectModel: {representativeKey: 'TransportationOrderItemUUID',
usageType: {serviceQuality: #D,
sizeCategory: #XXL,
dataClass: #MIXED},
modelingPattern: #NONE,
supportedCapabilities: [#CDS_MODELING_DATA_SOURCE,
#CDS_MODELING_ASSOCIATION_TARGET,
#SQL_DATA_SOURCE,
#EXTRACTION_DATA_SOURCE,
#ANALYTICAL_PROVIDER,
#ANALYTICAL_DIMENSION],
sapObjectNodeType.name: 'TransportationOrderItem'}
@VDM: {viewType: #COMPOSITE}
@Analytics: {dataCategory: #DIMENSION,
dataExtraction: {enabled: true,
delta.changeDataCapture: {
mapping:[
{
table: '/scmtms/d_torite', role: #MAIN,
viewElement: ['TransportationOrderItemUUID'],
tableElement: ['db_key']
}
]}
},
internalName: #LOCAL}
// view origin in Private Cloud; not relevant in Public Cloud
@VDM.lifecycle: {status: #DEPRECATED,
successor: 'I_TransportationOrderItem_2'}
define view I_TranspOrdItemAnalytics
as select from I_TransportationOrderItem
association [1..1] to I_TransportationOrderAnalytics as _TransportationOrderAnalytics on $projection.TransportationOrderUUID = _TransportationOrderAnalytics.TransportationOrderUUID
association [0..1] to I_TranspOrdStopAnalytics as _SourceStopAnalytics on $projection.SourceStopUUID = _SourceStopAnalytics.TransportationOrderStopUUID
association [0..1] to I_TranspOrdStopAnalytics as _DestinationStopAnalytics on $projection.DestinationStopUUID = _DestinationStopAnalytics.TransportationOrderStopUUID
association [0..*] to I_TranspOrdExecutionAnalytics as _TranspOrdExecutionAnalytics on $projection.TransportationOrderItemUUID = _TranspOrdExecutionAnalytics.TransportationOrderItemUUID
association [1..1] to I_TransportationOrderAnalytics as _PrdcssrTranspOrdAnlyts on $projection.PredecessorTransportationOrder = _PrdcssrTranspOrdAnlyts.TransportationOrderUUID
association [1..1] to I_TranspOrdItemAnalytics as _TranspOrdItemParentItemAnlyts on $projection.TranspOrdItemParentItemUUID = _TranspOrdItemParentItemAnlyts.TransportationOrderItemUUID
association [0..1] to I_MultiItem as _MultiItem on $projection.MultiItem = _MultiItem.MultiItem
{
// UUIDs
@Semantics.uuid: true
key TransportationOrderItemUUID,
@ObjectModel.foreignKey.association: '_TransportationOrderAnalytics'
@Semantics.uuid: true
TransportationOrderUUID,
@ObjectModel.foreignKey.association: '_TranspOrdItemParentItemAnlyts'
@Semantics.uuid: true
TranspOrdItemParentItemUUID,
@ObjectModel.foreignKey.association: '_SourceStopAnalytics'
@Semantics.uuid: true
cast(SourceStopUUID as /scmtms/vdm_tor_itm_s_stp_uuid preserving type) as SourceStopUUID,
@ObjectModel.foreignKey.association: '_DestinationStopAnalytics'
@Semantics.uuid: true
cast(DestinationStopUUID as /scmtms/vdm_tor_itm_d_stp_uuid preserving type) as DestinationStopUUID,
// Attributes (Characteristics)
cast(TranspOrdItem as /scmtms/vdm_item_id preserving type) as TranspOrdItem,
@Semantics.text: true
cast (TranspOrdItemDesc as /scmtms/vdm_item_description preserving type) as TranspOrdItemDesc,
@ObjectModel.foreignKey.association: '_TranspOrdItemType'
TranspOrdItemType,
@ObjectModel.foreignKey.association: '_TranspOrdItemCategory'
cast (TranspOrdItemCategory as /scmtms/vdm_item_category preserving type) as TranspOrdItemCategory,
@ObjectModel.foreignKey.association: '_Shipper'
Shipper,
@ObjectModel.foreignKey.association: '_Consignee'
Consignee,
// should be TranspOrdItemTranspMode! when used in views above or beside root-TransportationMode, cast to TranspOrdItemTranspMode
@ObjectModel.foreignKey.association: '_TransportationMode'
cast (TransportationMode as /scmtms/vdm_tor_trmodcode preserving type ) as TransportationMode,
// should be TranspOrdItemTranspModeCat! when used in views above or beside root-TransportationModeCategory, cast to TranspOrdItemTranspModeCat
@ObjectModel.foreignKey.association: '_TransportationModeCategory'
cast (TransportationModeCategory as /scmtms/vdm_tor_trmod_cat preserving type ) as TransportationModeCategory,
@ObjectModel.foreignKey.association: '_PrdcssrTranspOrdAnlyts'
PredecessorTransportationOrder,
@ObjectModel.foreignKey.association: '_BusTransDocTypeCode'
TranspOrdDocReferenceType,
TranspOrdDocReferenceItmType,
// foreign key association not necessary (ID)
TranspOrdDocReferenceID,
// foreign key association not necessary (ID)
TranspOrdDocReferenceItmID,
// foreign key association not available
cast (TranspOrdItemIsDangerousGood as /scmtms/vdm_dang_goods_ind preserving type) as TranspOrdItemIsDangerousGood,
// Product Information
ProductUUID,
@ObjectModel.foreignKey.association: '_Product'
ProductID,
@Semantics.text: true
ProductName,
// @ObjectModel.foreignKey.association: '_MaterialFreightGroup'
// MaterialFreightGroup,
// @Semantics.text: true
// cast(MaterialFreightGroupName as /scmtms/vdm_mfrgr_t preserving type) as MaterialFreightGroupName,
@ObjectModel.foreignKey.association: '_TransportationGroup'
TransportationGroup,
@Semantics.text: true
cast(TransportationGroupName as /scmtms/vdm_ttgrt_t preserving type) as TransportationGroupName,
@ObjectModel.foreignKey.association: '_MeansOfTransport'
// cast as TranspOrdMeansOfTransport in using views necessary (C1 incompatibe here)
cast(MeansOfTransport as /scmtms/vdm_tor_mot preserving type) as MeansOfTransport,
@ObjectModel.foreignKey.association: '_MultiItem'
cast(IsMultiItem as /scmtms/vdm_multi_item preserving type) as MultiItem,
// Supplements for Analytics
cast(TranspOrdItemSorting as /scmtms/vdm_tor_item_sort_id preserving type) as TranspOrdItemSorting,
ShipperUUID,
ConsigneeAddressID,
ConsigneeUUID,
@ObjectModel.foreignKey.association: '_IncotermsClassification'
IncotermsClassification,
cast(TranspOrdItemVoyage as /scmtms/vdm_i_voyage_id preserving type) as TranspOrdItemVoyage,
cast(TranspOrdItemFlight as /scmtms/vdm_i_flight_code preserving type) as TranspOrdItemFlight,
cast(TranspOrdItemVessel as /scmtms/vdm_i_vessel_id preserving type) as TranspOrdItemVessel,
cast(TranspOrdItemIMOShip as /scmtms/vdm_i_imo_id preserving type) as TranspOrdItemIMOShip,
@ObjectModel.foreignKey.association: '_Plant'
Plant,
// foreign key association not available
TranspOrdItmEquipmentGroup,
// foreign key association not available
TranspOrdItmEquipmentType,
// foreign key association not available
TranspOrdBookingConfSts,
// Booleans
@Semantics.booleanIndicator:true
CargoIsHighValue,
@Semantics.booleanIndicator:true
IsMainCargoItem,
// Measures (Key Figures) and Units
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemGrossWeightUnit'
@DefaultAggregation: #SUM
TranspOrdItemGrossWeight,
@ObjectModel.foreignKey.association: '_TranspOrdItemGrossWeightUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemGrossWeightUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemGrossVolumeUnit'
@DefaultAggregation: #SUM
TranspOrdItemGrossVolume,
@ObjectModel.foreignKey.association: '_TranspOrdItemGrossVolumeUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemGrossVolumeUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemNetWeightUnit'
@DefaultAggregation: #SUM
TranspOrdItemNetWeight,
@ObjectModel.foreignKey.association: '_TranspOrdItemNetWeightUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemNetWeightUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemQuantityUnit'
@DefaultAggregation: #SUM
TranspOrdItemQuantity,
@ObjectModel.foreignKey.association: '_TranspOrdItemQuantityUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemQuantityUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemAltvQtyUnit'
@DefaultAggregation: #SUM
TranspOrdItemAltvQty,
@ObjectModel.foreignKey.association: '_TranspOrdItemAltvQtyUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemAltvQtyUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemBaseQtyUnit'
@DefaultAggregation: #SUM
TranspOrdItemBaseQty,
@ObjectModel.foreignKey.association: '_TranspOrdItemBaseQtyUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemBaseQtyUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemTareWeightUnit'
@DefaultAggregation: #SUM
TranspOrdItemTareWeight,
@ObjectModel.foreignKey.association: '_TranspOrdItemTareWeightUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemTareWeightUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemNumberOfCtnsUnit'
@DefaultAggregation: #SUM
TranspOrdItemNumberOfCtns,
@ObjectModel.foreignKey.association: '_TranspOrdItemNumberOfCtnsUnit'
@Semantics.unitOfMeasure: true
TranspOrdItemNumberOfCtnsUnit,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemLengthUnit'
cast(TranspOrdItemLength as /scmtms/vdm_itm_length preserving type) as TranspOrdItemLength,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemLengthUnit'
cast(TranspOrdItemWidth as /scmtms/vdm_itm_width preserving type) as TranspOrdItemWidth,
@Semantics.quantity.unitOfMeasure: 'TranspOrdItemLengthUnit'
cast(TranspOrdItemHeight as /scmtms/vdm_itm_height preserving type) as TranspOrdItemHeight,
@ObjectModel.foreignKey.association: '_TranspOrdItemLengthUnit'
@Semantics.unitOfMeasure: true
cast(TranspOrdItemLengthUnit as /scmtms/vdm_itm_measuom preserving type) as TranspOrdItemLengthUnit,
@Semantics.amount.currencyCode: 'TranspOrdItemGoodsValueCrcy'
@DefaultAggregation: #SUM
cast(TranspOrdItemGoodsValue as /scmtms/vdm_amount) as TranspOrdItemGoodsValue,
// use new GFN TranspOrdItemGoodsValueAmount in views above!
@ObjectModel.foreignKey.association: '_GoodsValCurrency'
@Semantics.currencyCode: true
TranspOrdItemGoodsValueCrcy,
/* Associations */
// defined in this view
_TransportationOrderAnalytics,
_SourceStopAnalytics,
_DestinationStopAnalytics,
_TranspOrdExecutionAnalytics,
_MultiItem,
_PrdcssrTranspOrdAnlyts,
_TranspOrdItemParentItemAnlyts,
// propagated from underlying view
_TransportationOrder,
_Shipper,
_Consignee,
_TranspOrdItemType,
_TranspOrdItemCategory,
_TransportationMode,
_TransportationModeCategory,
_BusTransDocTypeCode,
_MeansOfTransport,
_TranspOrdItemGrossWeightUnit,
_TranspOrdItemGrossVolumeUnit,
_TranspOrdItemNetWeightUnit,
_TranspOrdItemQuantityUnit,
_TranspOrdItemAltvQtyUnit,
_TranspOrdItemBaseQtyUnit,
_TranspOrdItemTareWeightUnit,
_TranspOrdItemNumberOfCtnsUnit,
_TranspOrdItemLengthUnit,
_GoodsValCurrency,
_Product,
_TransportationGroup,
_Plant,
_IncotermsClassification
// _MaterialFreightGroup,
}